mdbook/sitefix-book/README.md
2024-08-14 19:09:13 +01:00

35 lines
656 B
Markdown

# SiteFix Book
A book example under some path set with **site-url**
## How to use it
- Create a **dist** path
- Run **mdbook** (fixed version release build from this repo)
```bash
../target/release/mdbook build --dest-dir dist/doc
```
**doc** is <u>absolute-path</u> declared in **book.toml** as **site-url**
```toml
[output.html]
site-url = "/doc/"
```
**doc** is <u>absolutec-path</u> declared in **context.toml** as **urlbase** and used as {{urlbase}}
```toml
urlbase = "/doc/"
```
Results can be tested simply by:
```bash
cd dist
python3 -m http.server
```
Navigate with a browser to [http://localhost:8000/doc](http://localhost:8000/doc)