#jet-engine
More complete documentation to follow.
jet-engine is a template engine with syntax very similar to dustjs-linked in. It was written because I needed a template engine that was more compact and less complicated to use than dustjs, but I liked dustjs syntax, compared to other template engine like handlebars. In the few cases in which I wanted templates to behave differently, I implemented my preferred way. I also had no requirement for asynchronous template handing, so I left that out.
Usage
If you know dustjs template syntax, you know jet-engine syntax. Here are some some examples.
import { render } from 'jet-engine';
const out = render('Hello, {name}!', { name: 'World' }); // Hello, World!
All the familiar keywords are implemented,
{#section}
{?test}
{!not} // also supports {^not} syntax for compatability
{@eq ...} // and other helpers
{>partials}
{<inline-partials}
{+blocks}
{~gt} // and other special characters
Partials
Register a partial like this
import { render, register } from 'jet-engine';
register('greet', 'Hello, {name}!')
const out = render('{>greet}', { name: 'Jim' });
const out = render('{>greet name='Jim'}'); // or provide data as an attribute
Many more examples and additional documentation to follow