Write is a template for markdown projects designed especially for tabletop role-playing texts.
The HTML output is intended to integrate with BookShelf for presentation, but that's far from a requirement.
To get started, fork and clone the repository.
# assuming github cli
gh repo fork https://github.com/Nevenall/write --clone=true
cd write
npm install
# you'll want to install the gulp cli globally
npm i gulp-cli -g
Add your markdown files to the \src
directory. We refer to them as chapters, and recommend they be lower kabab cased. Also, you'll be happier if each file has exactly one top level header.
Spelling can be checked using a gulp task.
gulp spelling
The output will indicate spelling errors and provide suggestions, but corrections are left to the user to build the muscle memory for correctness. :)
You can get advice about your prose by running
gulp prose
Check your word counts with
gulp count
write
supports a number of extensions to markdown designed for tabletop role-playing games. Most of these are uses of remark-directive
Sidebars are intended for content loosely related to the main text and are rendered in <aside>
tags.
You can add attributes using braces.
:::sidebar{.left}
This is a wry comment about something in the main text.
:::
<aside class="left">
<p>
This is a wry comment about something in the main text.
</p>
</aside>
Callouts are intensifications of a topic from, or associated to, the main text. They are rendered in <article>
tags.
:::callout{.right}
###### When writing a callout
It's probably a good idea to continue the heading levels as if this was a part of the main text.
Though that depends on how your HTML will eventually be styled.
:::
To compile your markdown to HTML in the /html
directory run
gulp build
This task will also produce rendering advice about your markdown.
The output of a write project integrates directly with BookShelf for presentation as an offline-first PWA.
Includes custom tweaks to convert internal links to .md files to .html files upon compile.
Includes vs code integration to execute Gulp tasks and a problem matcher for spell checking.