{"name":"pug-loader","version":"1.0.2","description":"The pug loader is responsible for loading the depenendencies of a given pug file.","keywords":["pug"],"dependencies":{"pug-walk":"0.0.3"},"devDependencies":{"pug-lexer":"^1.0.0","pug-parser":"^1.0.0"},"scripts":{"test":"node test"},"repository":{"type":"git","url":"git+https://github.com/pugjs/pug-loader.git"},"author":{"name":"ForbesLindesay"},"license":"MIT","gitHead":"838b12aefae7f190f1a74302f56dbc1bc60e6353","bugs":{"url":"https://github.com/pugjs/pug-loader/issues"},"homepage":"https://github.com/pugjs/pug-loader#readme","_id":"pug-loader@1.0.2","_shasum":"5a8bee1b81bd6781e3c0b5a068c722c6c858f946","_from":".","_npmVersion":"3.8.3","_nodeVersion":"5.10.1","_npmUser":{"name":"forbeslindesay","email":"forbes@lindesay.co.uk"},"maintainers":[{"name":"forbeslindesay","email":"forbes@lindesay.co.uk"},{"name":"timothygu","email":"timothygu99@gmail.com"}],"dist":{"shasum":"5a8bee1b81bd6781e3c0b5a068c722c6c858f946","tarball":"http://registry-npm.ywwl.com/pug-loader/download/pug-loader-1.0.2.tgz","integrity":"sha512-MtJ3E8zSexPCGtf2dPKSlgxxi6CotCPf4jFPsbt9MgQmtZsPfMWCrnVM6zqIc9LiJLIKd5Va5P+Tp3jJeTIp/w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCLi8XynaMp4FKV/iWBfzcAFCZpXjQOQ4exdQ30Hrv/mgIhAISaOV5gVsTkuP/xUKMMo7WVAlydMBs4HuN2PHCm57+m"}],"size":4005,"noattachment":false,"key":"/pug-loader/-/pug-loader-1.0.2.tgz"},"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/pug-loader-1.0.2.tgz_1460896187476_0.1502466006204486"},"deprecated":"Please use pug-load for pug-loader@<=1.0.2.","directories":{},"readme":"# pug-loader\n\nPug loader for webpack.\n\n## Usage\n\n``` javascript\nvar template = require(\"pug-loader!./file.pug\");\n// => returns file.pug content as template function\n\n// or, if you've bound .pug to pug-loader\nvar template = require(\"./file.pug\");\n\nvar locals = { /* ... */ };\n\nvar html = template(locals);\n// => the rendered HTML\n```\n\nFor more information on how to use webpack loaders, check the [official documentation][using-loaders].\n\nIn order to obtain the rendered HTML at compile time, combine this loader with [`apply-loader`](https://github.com/mogelbrod/apply-loader):\n\n```\nvar html = require(\"apply-loader!pug-loader!./file.pug\");\n// => the HTML is rendered at compile time\n```\n\n### Legacy `.jade` files\n\npug-loader fully supports `.jade` files. Just use pug-loader with `.jade` files as you would with a `.pug` file.\n\n### Includes\n\nIf you are using [includes], you must make sure that `.pug` (and if needed for legacy files, `.jade`) is bound to pug-loader. Check the webpack documentation on how to do that for [CLI][module-bind-cli] and for [configuration files][module-bind-config].\n\n### Options\n\nThe following [options] are available to be set for the loader. They are all mapped directly to Pug options, unless pointed out otherwise.\n\n- `doctype`\n  - Unlike Pug, it defaults to `\"html\"` if not set\n- `globals`\n- `self`\n- `plugins`\n  - Note that you cannot specify any Pug plugins implementing `read` or `resolve` hooks, as those are reserved for the loader\n- `pretty`\n- `filters`\n- `root`\n  - webpack uses its own file resolving mechanism, so while it is functionally equivalent to the Pug option with the same name, it is implemented differently\n\n### Embedded resources\n\nTry to use `require` for all your embedded resources, to process them with webpack.\n\n```pug\ndiv\n  img(src=require(\"./my/image.png\"))\n```\n\nRemember, you need to configure loaders for these file types too. You might be interested in the [file loader][file-loader].\n\n## License\n\n[MIT][mit]\n\n[file-loader]: https://github.com/webpack/file-loader\n[includes]: https://pugjs.org/language/includes.html\n[mit]: https://www.opensource.org/licenses/mit-license.php\n[module-bind-cli]: https://webpack.js.org/concepts/loaders/#via-cli\n[module-bind-config]: https://webpack.js.org/concepts/loaders/#configuration\n[options]: https://webpack.js.org/configuration/module/#useentry\n[using-loaders]: https://webpack.js.org/loaders\n","publish_time":1460896188609,"_cnpm_publish_time":1460896188609,"dist-tags":{"latest":"2.4.0"}}