Skip to content

Commit 42d389f

Browse files
committed
docs: wip
1 parent c2bcb14 commit 42d389f

File tree

5 files changed

+57
-5
lines changed

5 files changed

+57
-5
lines changed
169 KB
Loading

docs/source/features.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Features
2+
3+
## How to add frontend dependency
4+
5+
1. npm i -D ...
6+
7+
## How to add Sphinx extension to sample docs
8+
9+
1. Add extension to `dependencies` list in `sample_docs/pyproject.toml`.
10+
1. Add extension to `extensions` list in `conf.py`.

docs/source/index.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,7 @@
77
:maxdepth: 2
88
99
quickstart
10+
features
11+
usage
12+
reference
1013
```

docs/source/reference.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Reference
2+
3+
## File layout structure
4+
5+
{{ project }} follows a fairly specific file system layout. This standardized structure eases maintenance and switching between multiple projects.
6+
7+
All tasks, like build and preview, are in the [noxfile.py file](#nox-tasks), and this documentation assumes the structure.
8+
9+
```
10+
.
11+
├── build/ ┐
12+
│ └── <builder>/ | Output files
13+
│ └── <language>/ |
14+
│ └── ... ┘
15+
├── source/ ┐
16+
│ ├── _static/ |
17+
│ │ ├── favicon.svg |
18+
│ │ └── logo.svg |
19+
│ ├── _templates/ | Sphinx project sources
20+
│ ├── conf.py | (documents, images, conf.py)
21+
│ ├── index.md |
22+
│ ├── overview.md |
23+
│ └── ... ┘
24+
├── .gitignore ┐
25+
├── CHANGELOG.md |
26+
├── LICENSE |
27+
├── noxfile.py | Meta files
28+
├── package-lock.json |
29+
├── package.json |
30+
└── pyproject.toml ┘
31+
```
32+
33+
The files and folders are for three purposes:
34+
35+
- Sphinx project sources. Regular files found in Sphinx projects like .md, .rst, images, conf.py.
36+
- When built by [tasks](#nox-tasks), output goes to (by default) to `build/`.
37+
- Meta files. Not the documentation itself. Like dependencies in `pyproject.toml`, license, standard `.gitignore`, etc.
38+
39+
Everything except the output directory should be versioned.

docs/source/usage.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ orphan: true
44

55
# Usage
66

7-
## Add frontend dependency
7+
{#nox-tasks}
88

9-
npm i -D ...
9+
## noxfile tasks
1010

11-
## Update sample docs
11+
### preview
1212

1313
In preview mode, Python (Sphinx) and Node.js (Tailwind) part runs in parallel. To distinct the terminal output, both are prefixed with their names.
1414

@@ -28,8 +28,8 @@ The `package.json` must contain the following `scripts` tasks. They are called b
2828
"scripts": {
2929
"theme:build": "...",
3030
"theme:watch": "..."
31-
}
32-
}
31+
},
32+
...
3333
```
3434

3535
For example, if you want to build just Node.js assets, call `npm run theme:build`.

0 commit comments

Comments
 (0)