Clarification about interpolation setting in the README. Fixes #29

Closes gh-34.
This commit is contained in:
Mason Stewart 2013-10-23 00:34:59 -04:00 committed by Tyler Kellen
parent 38ee6e22d4
commit 37326b9a58
2 changed files with 4 additions and 2 deletions

View File

@ -1,4 +1,4 @@
# grunt-contrib-jst [![Build Status](https://travis-ci.org/gruntjs/grunt-contrib-jst.png?branch=master)](https://travis-ci.org/gruntjs/grunt-contrib-jst) # grunt-contrib-jst v0.5.1 [![Build Status](https://travis-ci.org/gruntjs/grunt-contrib-jst.png?branch=master)](https://travis-ci.org/gruntjs/grunt-contrib-jst)
> Precompile Underscore templates to JST file. > Precompile Underscore templates to JST file.
@ -144,6 +144,7 @@ jst: {
} }
} }
``` ```
Note that the `interpolate: /\{\{(.+?)\}\}/g` setting above is simply an example of overwriting lodash's default interpolation. If you want to parse templates with the default `_.template` behavior (i.e. using `<div><%= this.id %></div>`), there's no need to overwrite `templateSettings.interpolate`.
## Release History ## Release History
@ -164,4 +165,4 @@ jst: {
Task submitted by [Tim Branyen](http://tbranyen.com) Task submitted by [Tim Branyen](http://tbranyen.com)
*This file was generated on Sun Jul 14 2013 19:23:02.* *This file was generated on Sat Oct 19 2013 14:22:27.*

View File

@ -14,3 +14,4 @@ jst: {
} }
} }
``` ```
Note that the `interpolate: /\{\{(.+?)\}\}/g` setting above is simply an example of overwriting lodash's default interpolation. If you want to parse templates with the default `_.template` behavior (i.e. using `<div><%= this.id %></div>`), there's no need to overwrite `templateSettings.interpolate`.