From c614436d29a11ddbb1218485a05da7dde0e57038 Mon Sep 17 00:00:00 2001 From: Humberto Alfonso Díaz Date: Fri, 5 Jul 2019 11:15:05 +0200 Subject: FUNCT Add buttons, fan speed and chair functionality --- webpack.config.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'webpack.config.js') diff --git a/webpack.config.js b/webpack.config.js index e6baeb2..ed7e0a3 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -9,10 +9,18 @@ const ZipPlugin = require('zip-webpack-plugin'); module.exports = { mode: 'production', - entry: './src/index.js', + entry: { + index: './src/index.js', + FANSPEED: './src/js/fan_speed.js', + CHAIR: './src/js/chair.js', + BUTTON: './src/js/buttons.js' + }, output: { - filename: 'index.js', - path: __dirname + '/dist' + path: __dirname + '/dist', + filename: '[name].js', + libraryTarget: 'var', + // `library` determines the name of the global variable + library: '[name]' }, optimization: { minimizer: [new UglifyJsPlugin()], -- cgit 1.2.3-korg