typo
Advanced tools
Comparing version 1.0.3 to 1.0.4
{ | ||
"name": "typo", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "`typo` is an extendable template engine designed for the future", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -74,3 +74,3 @@ [![Build Status](https://travis-ci.org/kaelzhang/node-typo.svg?branch=master)](https://travis-ci.org/kaelzhang/node-typo) | ||
``` | ||
```js | ||
const template = typo.compile(`Once in a {{blue color}} moon`) | ||
@@ -83,5 +83,12 @@ | ||
## typo({open, close}) | ||
Creates the `typo` instance. | ||
- **open** `String={{` The beginning of each directive. | ||
- **close** `String=}}` The end of each directive. | ||
## compile(template, compile_options) | ||
Returns `function(data)` | ||
Compiles a template into a function. | ||
@@ -94,2 +101,4 @@ - **template** `String` | ||
Returns `function(data)` | ||
async: false | ||
@@ -96,0 +105,0 @@ |
132296
133