Created
July 17, 2012 21:57
-
-
Save bkw/3132425 to your computer and use it in GitHub Desktop.
difference in behaviour between lodash.js and lodash.min.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
var _ = require('./lodash.js')._, | |
_min = require('./lodash.min.js')._, | |
t = '{{ demo.join(",") }}', | |
data = { demo: ['a', 'b'] }; | |
_.templateSettings = _min.templateSettings = { | |
interpolate : /\{\{(.+?)\}\}/g | |
}; | |
console.log( _.template(t)(data) ); | |
console.log( _min.template(t)(data) ); |
Author
bkw
commented
Jul 17, 2012
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment