XJST-based compiler for a BEM-specific templates.
Install it by npm: npm install bem
.
var BEM_XJST = require('bem-xjst'),
template = BEM_XJST.compile('... your source code ...');
template.apply(/* ... your input data here ... */);
$ bem-xjst --help
Usage:
bem-xjst [OPTIONS] [ARGS]
Options:
-h, --help : Help
-v, --version : Version
-d, --dev-mode : Dev mode
-i INPUT, --input=INPUT : Input file (default: stdin)
-o OUTPUT, --output=OUTPUT : Output file (default: stdout)