{"name":"grunt-sails-linker","description":"Autoinsert script and link tags in an html file.","version":"1.0.4","homepage":"http://sailsjs.com","contributors":[{"name":"scott-laursen","url":"www.addgo.com"},{"name":"Zolmeister","url":"http://zolmeister.com"},{"name":"Mike McNeil","url":"http://mikermcneil.com"}],"repository":{"type":"git","url":"git+https://github.com/sailsjs/grunt-sails-linker.git"},"main":"Gruntfile.js","engines":{"node":">= 0.10.0"},"scripts":{"test":"grunt test"},"devDependencies":{"grunt-contrib-jshint":"0.10.0","grunt-contrib-clean":"0.6.0","grunt-contrib-nodeunit":"0.4.1","grunt":"0.4.5"},"keywords":["gruntplugin","sails","linker"],"license":"MIT","gitHead":"958b2d109e39fd5941ec514d1289608fc381589a","bugs":{"url":"https://github.com/sailsjs/grunt-sails-linker/issues"},"_id":"grunt-sails-linker@1.0.4","_shasum":"2b7d690d522aa04327f8f3f80dffd6668bb3b5c2","_from":".","_npmVersion":"2.14.12","_nodeVersion":"4.3.0","_npmUser":{"name":"mikermcneil","email":"michael.r.mcneil@gmail.com"},"dist":{"shasum":"2b7d690d522aa04327f8f3f80dffd6668bb3b5c2","tarball":"http://registry-npm.ywwl.com/grunt-sails-linker/download/grunt-sails-linker-1.0.4.tgz","integrity":"sha512-kCWD11IYrJVDRPXBnQcc0JMyhHBkqcVa+bDEB2yDPg7VO9AdEVRtRT5sZrgrn1znr5XL5UlJO0jiOYOVBfZDzA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIQDB0gvyh6RoC2fRDjtj2a+DwOXtl1oMkr9gtTJiY6QOHwIfVRxP4tHs/bmR1a/2lPkL5ZACchLZ5lw9PQZ0EhWl/Q=="}],"size":3476,"noattachment":false,"key":"/grunt-sails-linker/-/grunt-sails-linker-1.0.4.tgz"},"maintainers":[{"name":"zolmeister","email":"zolikahan@gmail.com"},{"name":"balderdashy","email":"mike@balderdash.co"},{"name":"mikermcneil","email":"michael.r.mcneil@gmail.com"}],"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/grunt-sails-linker-1.0.4.tgz_1478221867172_0.5075639605056494"},"directories":{},"readme":"# grunt-sails-linker\n\n> Autoinsert script tags (or other filebased tags) in an html file.\n\n## Getting started\nThis plugin requires Grunt `~0.4.x` or `^1.0.0`.\n\nWhen the task is run, the destination file(s) is updated with script tags pointing to all the source files. The reason this plugin was built was to automate the process of inserting script tags when building large web apps.\n\n```shell\nnpm install grunt-sails-linker --save-dev\n```\n\nOnce the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:\n\n```js\ngrunt.loadNpmTasks('grunt-sails-linker');\n```\n\n## The \"sails-linker\" task\n\n### Overview\nIn your project's Gruntfile, add a section named `sails-linker` to the data object passed into `grunt.initConfig()`.\n\n```js\ngrunt.initConfig({\n  'sails-linker': {\n    defaultOptions: {\n      options: {\n        startTag: '<!--SCRIPTS-->',\n        endTag: '<!--SCRIPTS END-->',\n        fileTmpl: '<script src=\"%s\"></script>',\n        appRoot: 'app/'\n      },\n      files: {\n        // Target-specific file lists and/or options go here.\n        'app/index.html': ['app/scripts/**/*.js']\n      },\n    },\n  },\n})\n```\n\n### Options\n\n#### options.startTag\nType: `String`\nDefault value: `'<!--SCRIPTS-->'`\n\nScript tags are places between the startTag and endTag\n\n#### options.endTag\nType: `String`\nDefault value: `'<!--SCRIPTS END-->'`\n\nScript tags are places between the startTag and endTag\n\n#### options.fileTmpl\nType: `String`\nDefault value: `'<script src=\"%s\"></script>'`\n\nThe template used to insert the reference to the script files.\n\n#### options.fileRef\nType: `Function`\nDefault value: `undefined`\n\nOptional function which takes the `filepath` as argument and returns a `String` inserted as reference to the script file. Note that `option.fileRef` takes precedence over `option.fileTmpl`.\n\n#### options.appRoot\nType: `String`\nDefault value: `''`\n\nThe root of the application. Script links are relative from this folder.\n\n#### options.relative\nType: `Boolean`\nDefault value: `false`\n\nReference files using a relative url.\n\n#### options.inline\nType: `Boolean`\nDefault value: `false`\n\nPass the contents of a file rather than the filepath into `fileTmpl`.  For example, if `options.inline` is set to `true` and `fileTmpl` is set to `<script>%s</script>`, the script contents will be injected between `<script>` tags.\n\n\n## Help\n\nFirst, please check out the relevant documentation in [Concepts > Assets](http://sailsjs.com/docs/concepts/assets).  If you have further questions or are having trouble, click [here](http://sailsjs.com/support).\n\n\n## Bugs &nbsp; [![NPM version](https://badge.fury.io/js/grunt-sails-linker.svg)](http://npmjs.com/package/grunt-sails-linker)\n\nTo report a bug, [click here](http://sailsjs.com/bugs).\n\n\n## Contributing\n\nPlease observe the guidelines and conventions laid out in the [Sails project contribution guide](http://sailsjs.com/contribute) when opening issues or submitting pull requests.\n\n[![NPM](https://nodei.co/npm/grunt-sails-linker.png?downloads=true)](http://npmjs.com/package/grunt-sails-linker)\n\n\n## License\n\nCopyright &copy; 2013 [Scott Laursen](http://github.com/scott-laursen)\nCopyright &copy; 2013 [Zoli Kahan](http://github.com/Zolmeister)\n\nThe [Sails framework](http://sailsjs.com) is free and open-source under the [MIT License](http://sailsjs.com/license).\n","publish_time":1478221867706,"_cnpm_publish_time":1478221867706,"dist-tags":{"latest":"1.0.4"}}