{"name":"minstache","version":"1.1.0","description":"Mini mustache template engine","keywords":["mustache","template","engine"],"author":{"name":"TJ Holowaychuk","email":"tj@vision-media.ca"},"dependencies":{"commander":"1.0.4"},"devDependencies":{"mocha":"*","should":"*"},"bin":{"minstache":"bin/minstache"},"main":"index","_id":"minstache@1.1.0","dist":{"shasum":"5c2e11f4214ea670211a7d6ca3a273ac9bc43730","tarball":"http://registry-npm.ywwl.com/minstache/download/minstache-1.1.0.tgz","integrity":"sha512-i+l+WpqxXEg/4PNcM51r7hlwlaSFMjr8ByHGpj6SYFD8rvAiewWZDt4XBN+iN0XWN5bv0B3rRRrEDyc+wjoLzA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFW9BEOM/wWuf+S/nsw/vQYm5viKHs5wN444YqcqyBCcAiEA88RVw9R0NROTifJgkAwckMWeA737ormkRGhK4k7tYwE="}],"size":2424,"noattachment":false,"key":"/minstache/-/minstache-1.1.0.tgz"},"_from":".","_npmVersion":"1.2.25","_npmUser":{"name":"tjholowaychuk","email":"tj@vision-media.ca"},"maintainers":[{"name":"tjholowaychuk","email":"tj@vision-media.ca"}],"directories":{},"readme":"\n# minstache\n\n  Mini mustache template engine.\n\n## Installation\n\n    $ npm install minstache\n    $ component install visionmedia/minstache\n\n## minstache(1)\n\n  The `minstache(1)` executable can compile a file to a valid\n  stand-alone commonjs module for you, there's no need to have minstache\n  as a dependency:\n\n  hello.mustache:\n\n```\nHello {{name}}! {{^authenticated}}<a href=\"/login\">login</a>{{/authenticated}}\n```\n\n  convert it:\n\n```\n$ minstache < hello.mustache > hello.js\n```\n\n  hello.js:\n\n```js\nmodule.exports = function anonymous(obj) {\n\n  function escape(html) {\n    return String(html)\n      .replace(/&/g, '&amp;')\n      .replace(/\"/g, '&quot;')\n      .replace(/</g, '&lt;')\n      .replace(/>/g, '&gt;');\n  };\n\n  function section(obj, prop, negate, str) {\n    var val = obj[prop];\n    if ('function' == typeof val) return val.call(obj, str);\n    if (negate) val = !val;\n    if (val) return str;\n    return '';\n  };\n\n  return \"Hello \" + escape(obj.name) + \"! \" + section(obj, \"authenticated\", true, \"<a href=\\\"/login\\\">login</a>\") + \"\\n\"\n}\n```\n\n## API\n\n### minstache(string, [obj])\n\n  Compile and render the given mustache `string` with optional context `obj`.\n\n### minstache.compile(string)\n\n  Compile the mustache `string` to a stand-alone `Function` accepting a context `obj`.\n\n## Divergence\n\n  Partials are not supported, this lib is meant to be a small template engine solution for stand-alone [component](http://github.com/component) templates. If your template takes \"partials\" then pass other rendered strings to it. If you need a full-blown mustache solution Hogan.js is still great.\n\n  Minstache uses `{{!name}}` for unescaped properties.\n\n## License\n\n  MIT\n","publish_time":1372965352043,"_cnpm_publish_time":1372965352043,"dist-tags":{"latest":"1.2.0"}}