/** * Simple `useref` in-line Plugin that ties into `html-webpack-plugin`. * * This will simply run `useref` and replace the HTML that will be processed. **/constHtmlWebpackPlugin=require('html-webpack-plugin');constuseref=require('useref');constAppName=JSON.parse(require('fs').readFileSync('./package.json')).name;module.exports={entry:{frontend:'./frontend/index.js'},plugins:[newHtmlWebpackPlugin({title:AppName,template:'./frontend/index.html'}),//NOTE: it's best to put this in it's own module, and only include if targeting a Production build.newclassWebpackUseref{apply(compiler){compiler.plugin('compilation',function(compilation){console.log('[webpack-useref-plugin] - Initializing');compilation.plugin('html-webpack-plugin-before-html-processing',function(htmlPluginData,callback){letresult=useref(htmlPluginData.html);htmlPluginData.html=result[0];callback(null,htmlPluginData);})});}}]}
Comments (1)
Telltims
Tim Hortons is one of the famous fast-food chain in entire Canada. They want to know their customers level of satisfaction of their services. So they conducts a customer feedback survey called Telltims at Telltims.ca survey. And also they offering some amazing gifts to participants. It means you can grab a chance to win a $1 Hot Chocolate, French Vanilla, or Iced Coffee by participating in this survey.
HTTPSSSH
You can clone a snippet to your computer for local editing.
Learn more.
Tim Hortons is one of the famous fast-food chain in entire Canada. They want to know their customers level of satisfaction of their services. So they conducts a customer feedback survey called Telltims at Telltims.ca survey. And also they offering some amazing gifts to participants. It means you can grab a chance to win a $1 Hot Chocolate, French Vanilla, or Iced Coffee by participating in this survey.