jstransformer-handlebars

Handlebars support for JSTransformers.

MIT 6 个版本
安装
npm install jstransformer-handlebars
yarn add jstransformer-handlebars
pnpm add jstransformer-handlebars
bun add jstransformer-handlebars
README

jstransformer-handlebars

Handlebars.js support for JSTransformers.

Build Status Coverage Status Dependency Status NPM version

Installation

npm install jstransformer-handlebars

API

var handlebars = require('jstransformer')(require('jstransformer-handlebars'));

var locals = {
  name: "World"
};

handlebars.render('<h1>Hello {{name}}!</h1>', {}, locals).body
//=> '<h1>Hello World!</h1>'

In addition to the standard Handlebars compile options, the render method can be passed objects for partials, helpers and decorators (deprecated).

License

MIT

版本列表
1.2.0 2022-01-17
1.1.0 2018-01-28
1.0.0 2015-09-03
0.1.0 2015-06-28
0.0.2 2015-04-02
0.0.1 2015-02-16