jtex
jtex
is a command line tool (CLI) for rendering documents from Jinja-style templates. This package uses nunjucks (a port of Jinja) as the template engine with a modified environment and syntax that plays well with 's markup.
Create a Template š
Learn how to create a template for a scientific journal article or Beamer presentation using jtex
and MyST Markdown.
Browse Templates š
Our templates are curated by the MyST community and include templates to render over 400 journals!
Command Line Interface āØ
Use jtex
to list templates, quickly render content, or fix your template.yml
, or parse your files for used packages.
#Project Goals
- Provide a data-driven templating markup for
- Provide validation of templates and supplied options when rendering a template
- Work with standardized frontmatter to make authors, affiliations, etc. easy to template
- Work with the MyST ecosystem of tools
- Support many user supplied templates, local templates, etc.
Not Goals
- Translation of MyST to , instead see
myst-to-tex
or using pandoc withjtex
#Installation
Install the package globally using npm:
npm install -g jtex
and confirm correct installation by typing:
jtex --version
#Usage with MyST
The main usage for jtex
is with myst
and curvenote
command line tools,
both of which can compile markdown into for templating with jtex
.
#Simple Example
A document can be used very simply with the document as doc
, the contents of which are
documented in Document Model. Be sure to include the [-IMPORTS-]
and the [-CONTENT-]
.
% template.tex
\documentclass{article}
[-IMPORTS-]
\title{[-doc.title-]}
\author{[-doc.authors[0].name-] ([-doc.authors[0].email-])}
\begin{document}
\maketitle
[-CONTENT-]
The End!
\end{document}