1 webpack实现多个输入输出多个html
entry:{ main: ‘./src/main.js‘, login: ‘./src/login.js‘ }, plugins: [ new HtmlWebpackPlugin({ filename: ‘index.html‘, template: ‘./src/index.html‘, chunks: [‘main‘] //将main.js插入到index.html内部, }), new HtmlWebpackPlugin({ filename: ‘login.html‘, template: ‘./src/login.html‘, chunks: [‘login‘] }) ],
原文地址:https://www.cnblogs.com/xhliang/p/8921175.html
时间: 2024-10-26 10:32:37