This is the renderer used by [Joplin](https://github.com/laurent22/joplin) to render notes in Markdown or HTML format.
## Installation
npm i -s joplin-renderer
Certain plugins require additional assets like CSS, fonts, etc. These assets are in the `/assets` directory and should be copied to wherever the application can find them at runtime.
Whenever updating a Markdown-it plugin, such as Katex or Mermaid, make sure to run `npm run buildAssets`, which will compile the CSS and JS for use in the Joplin applications.
A plugin (or rule) can have any number of assets, such as CSS or font files, associated with it. To add an asset to a plugin, follow these steps:
- Add the file under `/assets/PLUGIN_NAME/your-asset-file.css`
- Register this file within the plugin using `context.pluginAssets[PLUGIN_NAME] = [{ name: 'your-asset-file.css' }]`
See katex.js for an example of how this is done.
### Adding inline CSS
A plugin can ask for some CSS to be included inline in the rendered HTML. This is convenient as it means no extra file needs to be packaged. Use this syntax to do this: