Jennie.Tokeniser (jennie v0.9.1)
Turns a template string into a flat list of tokens.
Tokens are one of:
{:text, binary, line, col}{:tag, type, payload, line, col}
where type is one of :var, :unescaped, :section, :inverted,
:close, :comment, :partial, :delimiter. The payload is:
{:var, keys, escaped?, formatter}—keysis the dotted name split on".";formatterisnilor a list formatter (:ol,:and,:or,{:join, separator}) given after a pipe, e.g.{{items | and}}{:section | :inverted | :close, keys}{:partial, name}— the raw (unsplit) partial name{:comment, _}/{:delimiter, _}— content is irrelevant to output
Set-delimiter tags ({{=<% %>=}}) are applied during scanning so subsequent
tags use the new delimiters.
Summary
Functions
Tokenise source, returning {:ok, tokens} or raising Jennie.SyntaxError.