Skip to content

Commit 0324aaa

Browse files
committed
Update readme
1 parent a6f97a4 commit 0324aaa

File tree

1 file changed

+20
-6
lines changed

1 file changed

+20
-6
lines changed

README.md

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
# docpress-core
22

3-
How it works:
3+
Metalsmith plugin to generate Docpress site data from a project. Part of the [Docpress] project.
44

5-
1. make a toc in `docs/README.md`
6-
2. renders a site based on it
5+
This plugin generates bare HTML files (just rendered from Markdown) from a project. It also creates a `toc.json` (Table of contents) and `index.json` (Page index). This is usually used with [docpress-base], which will then prettify those pages into a full-fleged website.
76

8-
sample:
7+
## How it works
8+
9+
Make a TOC in `docs/README.md`. This will be used to crawl the project for files to be parsed. Here's an example structure:
910

1011
```
1112
README.md
@@ -18,5 +19,18 @@ docs/
1819

1920
## API
2021

21-
* `docpress-core` - Metalsmith middleware.
22-
* `docpress-core/ms` - Metalsmith instance generator.
22+
You get these modules:
23+
24+
- `docpress-core` The main Metalsmith middleware.
25+
- `docpress-core/ms` - Metalsmith instance generator.
26+
27+
You use them together like so:
28+
29+
```js
30+
var app = require('docpress-core/ms')(cwd)
31+
.use(require('docpress-core')())
32+
.use(require('docpress-base')())
33+
```
34+
35+
[Docpress]: https://github.com/docpress/docpress
36+
[docpress-base]: https://github.com/docpress/docpress-base

0 commit comments

Comments
 (0)