diff options
author | Determinant <ted.sybil@gmail.com> | 2019-02-07 01:32:45 -0500 |
---|---|---|
committer | Determinant <ted.sybil@gmail.com> | 2019-02-07 01:32:45 -0500 |
commit | 735d8e5aa8b590b37a16c0e1b52a688c43dd5c10 (patch) | |
tree | 3fa81f703a18a6c3780d22c7a27867392412dafe /webpack.config.js | |
parent | 608f68cba0fa98f2db31b95a1bbc4cabb98586ea (diff) |
add popup
Diffstat (limited to 'webpack.config.js')
-rw-r--r-- | webpack.config.js | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/webpack.config.js b/webpack.config.js index 0538655..5c387ee 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -5,7 +5,8 @@ const CopyWebpackPlugin = require('copy-webpack-plugin'); module.exports = { entry: { index: "./src/index.js", - background: "./src/background.js" + background: "./src/background.js", + popup: "./src/popup.js" }, output: { path: path.join(__dirname, "/dist"), @@ -29,15 +30,17 @@ module.exports = { }, plugins: [ new HtmlWebpackPlugin({ - template: "./public/index.html" + chunks: ['index'], + template: "./src/index.html", + filename: "./index.html" + }), + new HtmlWebpackPlugin({ + chunks: ['popup'], + template: "./src/index.html", + filename: "./popup.html" }), new CopyWebpackPlugin([ {from:'./public/', to:'./'} ]), ], - optimization: { - splitChunks: { - chunks: 'all' - } - } }; |