colon-template

1.0.3 • Public • Published

colon-template

simple inline template that uses colons. This probably already exists, but it's about as fast to make as find.

Example

var template = require('colon-template')
var fn = template('hi :friend, my name is :first_name and i am :age.years years and :age.months months old')
var locals = { friend: 'martha', first_name: 'matt', age: { years: 26 } }

Installation

npm install colon-template

License

MIT

Package Sidebar

Install

npm i colon-template

Weekly Downloads

95

Version

1.0.3

License

none

Last publish

Collaborators

  • mattmueller