{"_id":"helper-concat","_rev":"83618","name":"helper-concat","description":"Template helper for concatenating a list of files using glob patterns. Should work with handlebars, lodash or any template engine that allows helper functions.","dist-tags":{"latest":"0.3.0"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"time":{"modified":"2021-06-03T10:26:36.000Z","created":"2014-11-29T14:52:03.337Z","0.3.0":"2015-03-15T05:13:09.967Z","0.2.0":"2014-12-10T04:54:17.152Z","0.1.0":"2014-11-29T14:52:03.337Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/helper-concat.git"},"versions":{"0.3.0":{"name":"helper-concat","description":"Template helper for concatenating a list of files using glob patterns. Should work with handlebars, lodash or any template engine that allows helper functions.","version":"0.3.0","homepage":"https://github.com/jonschlinkert/helper-concat","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/helper-concat.git"},"bugs":{"url":"https://github.com/jonschlinkert/helper-concat/issues"},"license":{"type":"MIT","url":"https://github.com/jonschlinkert/helper-concat/blob/master/LICENSE"},"files":["index.js"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha"},"dependencies":{"async":"^0.9.0","extend-shallow":"^1.1.2","globby":"^1.2.0"},"devDependencies":{"handlebars":"^3.0.0","lodash":"^3.5.0","mocha":"^2.2.1","should":"^5.2.0"},"keywords":["concat","concatenate","content","files","glob","handlebars","helper","helpers","lo-dash","lodash","patterns","read","underscore","util","utils"],"gitHead":"2b84ddd2e84b350554224fb9c6b22b59bd45bf38","_id":"helper-concat@0.3.0","_shasum":"0506ab3f545f25750d9ffe3d772d28f21297532c","_from":".","_npmVersion":"2.5.1","_nodeVersion":"0.12.0","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"0506ab3f545f25750d9ffe3d772d28f21297532c","size":2844,"noattachment":false,"key":"/helper-concat/-/helper-concat-0.3.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/helper-concat/download/helper-concat-0.3.0.tgz"},"directories":{},"publish_time":1426396389967,"_cnpm_publish_time":1426396389967,"_hasShrinkwrap":false},"0.2.0":{"name":"helper-concat","description":"Template helper for concatenating a list of files using glob patterns. Should work with handlebars, lodash or any template engine that allows helper functions.","version":"0.2.0","homepage":"https://github.com/jonschlinkert/helper-concat","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/helper-concat.git"},"bugs":{"url":"https://github.com/jonschlinkert/helper-concat/issues"},"licenses":[{"type":"MIT","url":"https://github.com/jonschlinkert/helper-concat/blob/master/LICENSE-MIT"}],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"dependencies":{"async":"^0.9.0","extend-shallow":"^0.1.1","globby":"^1.0.0"},"devDependencies":{"handlebars":"^2.0.0","lodash":"^2.4.1","mocha":"*","should":"*"},"keywords":["concat","concatenate","content","files","glob","handlebars","helper","helpers","lo-dash","lodash","patterns","read","underscore","util","utils"],"_id":"helper-concat@0.2.0","_shasum":"57e00a32639d13351e939a3e1ed95db4dbe602d5","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"57e00a32639d13351e939a3e1ed95db4dbe602d5","size":3922,"noattachment":false,"key":"/helper-concat/-/helper-concat-0.2.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/helper-concat/download/helper-concat-0.2.0.tgz"},"directories":{},"publish_time":1418187257152,"_cnpm_publish_time":1418187257152,"_hasShrinkwrap":false},"0.1.0":{"name":"helper-concat","description":"Template helper for concatenating a list of files using glob patterns. Should work with handlebars, lodash or any template engine that allows helper functions.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/helper-concat","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/helper-concat.git"},"bugs":{"url":"https://github.com/jonschlinkert/helper-concat/issues"},"licenses":[{"type":"MIT","url":"https://github.com/jonschlinkert/helper-concat/blob/master/LICENSE-MIT"}],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"dependencies":{"globby":"^1.0.0"},"devDependencies":{"handlebars":"^2.0.0","lodash":"^2.4.1","mocha":"*","should":"*"},"keywords":["concat","concatenate","content","files","glob","handlebars","helper","helpers","lo-dash","lodash","patterns","read","underscore","util","utils"],"_id":"helper-concat@0.1.0","_shasum":"559d5a9bfe03d155c80b8b8adda3a87e805cbfda","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"559d5a9bfe03d155c80b8b8adda3a87e805cbfda","size":3547,"noattachment":false,"key":"/helper-concat/-/helper-concat-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/helper-concat/download/helper-concat-0.1.0.tgz"},"directories":{},"publish_time":1417272723337,"_cnpm_publish_time":1417272723337,"_hasShrinkwrap":false}},"readme":"# helper-concat [![NPM version](https://badge.fury.io/js/helper-concat.svg)](http://badge.fury.io/js/helper-concat)  [![Build Status](https://travis-ci.org/jonschlinkert/helper-concat.svg)](https://travis-ci.org/jonschlinkert/helper-concat) \n\n> Template helper for concatenating a list of files using glob patterns. Should work with handlebars, lodash or any template engine that allows helper functions.\n\n## Install with [npm](npmjs.org)\n\n```bash\nnpm i helper-concat --save\n```\n\n## Usage examples\n\n### [concat](./index.js#L46)\n\nGet the contatenated content from a glob of files.\n\n* `patterns` **{String}**    \n* `options` **{Options}**    \n* `returns`: {String}  \n\n```js\nvar concat = require('helper-concat');\n\nconcat('files/*.md', function(err, content) {\n  //=> 'AAA\\nBBB\\nCCC'\n});\n```\n\nAs a helper:\n\n```handlebars\n{{concat 'files/*.md'}}\n```\n\n### [.sync](./index.js#L82)\n\nSynchronously get the contatenated content from a glob of files.\n\n* `patterns` **{String}**    \n* `options` **{Options}**    \n* `returns`: {String}  \n\n```js\nvar concat = require('helper-concat');\n\nconcat('files/*.md');\n//=> 'AAA\\nBBB\\nCCC'\n```\n\nAs a helper:\n\n```handlebars\n{{concat 'files/*.md'}}\n```\n\n## Register the helper\n\n> This should work with any template engine, here are a few examples\n\n### [template]\n\nRegister the helper for use with any template engine\n\n```js\ntemplate.helper('concat', require('helper-concat'));\n```\n\n### [assemble]\n\nTo register the helper for use with [assemble] v0.6.x:\n\n```js\nassemble.helper('concat', require('helper-concat'));\n```\n\n### [verb]\n\nRegister the helper for use with [verb]:\n\n```js\nvar verb = require('verb');\nverb.helper('concat', require('helper-concat'));\n\nverb.task('default', function() {\n  verb.src('.verb*.md')\n    .pipe(verb.dest('./'));\n});\n```\n\n### [handlebars]\n\n```js\nvar handlebars = require('handlebars');\nhandlebars.registerHelper('concat', require('helper-concat'));\n```\n\n### [Lo-Dash] or [underscore]\n\n```js\nvar handlebars = require('handlebars');\nhandlebars.registerHelper('concat', require('helper-concat'));\n\n// as a mixin\n_.mixin({concat: concatHelper});\n_.template('<%= _.concat(\"fixtures/*.txt\") %>', {});\n//=> 'AAA\\nBBB\\nCCC'\n\n// passed on the context\nvar settings = {imports: {concat: concatHelper}};\n_.template('<%= concat(\"fixtures/*.txt\") %>', {concat: concatHelper});\n//=> 'AAA\\nBBB\\nCCC'\n\n// as an import\nvar settings = {imports: {concat: concatHelper}};\n_.template('<%= concat(\"fixtures/*.txt\") %>', {}, settings);\n//=> 'AAA\\nBBB\\nCCC'\n```\n\n## Running tests\nInstall dev dependencies.\n\n```bash\nnpm i -d && npm test\n```\n\n## Contributing\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/helper-concat/issues)\n\nTo request or contribute a helper to the [github.com/helpers][helpers] org, please read [this contributing guide][guide] to get started.\n\n## Author\n\n**Jon Schlinkert**\n \n+ [github/jonschlinkert](https://github.com/jonschlinkert)\n+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) \n\n## License\nCopyright (c) 2015 Jon Schlinkert  \nReleased under the MIT license\n\n***\n\n_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on March 15, 2015._\n\n[assemble]: https://github.com/assemble/assemble\n[generator-verb]: https://github.com/assemble/generator-verb\n[handlebars-helpers]: https://github.com/assemble/handlebars-helpers/\n[handlebars]: https://github.com/wycats/handlebars.js/\n[helpers]: https://github.com/helpers\n[Lo-Dash]: https://lodash.com/\n[template]: https://github.com/jonschlinkert/template\n[underscore]: https://github.com/jashkenas/underscore\n[verb]: https://github.com/assemble/verb\n[guide]: https://github.com/helpers/requests","_attachments":{},"homepage":"https://github.com/jonschlinkert/helper-concat","bugs":{"url":"https://github.com/jonschlinkert/helper-concat/issues"},"license":{"type":"MIT","url":"https://github.com/jonschlinkert/helper-concat/blob/master/LICENSE"}}