EJS loader for webpack. Uses ejs function to compile templates.
npm install ejs-loader
var template = require("ejs!./file.ejs");
// => returns the template function compiled with undesrcore (lodash) templating engine.
// And then use it somewhere in your code
template(data) // Pass object with data
module.exports = {
module: {
loaders: [
{
test: /\.ejs$/,
loader: 'ejs-loader'
},
]
}
};
- 0.0.1 - Initial release