CodiceFiscaleJS/webpack.config.js

20 lines
457 B
JavaScript
Raw Normal View History

2017-03-10 12:41:10 +01:00
const path = require('path'),
UglifyJSPlugin = require('uglifyjs-webpack-plugin');
2017-03-10 12:03:36 +01:00
module.exports = {
entry: {
'codice.fiscale': './src/codice.fiscale.js'
2017-03-10 12:03:36 +01:00
},
output: {
2017-03-10 12:46:46 +01:00
// this will publish the module on the window object in order to support the karma tests
2017-03-10 12:20:20 +01:00
library: 'CodiceFiscale',
libraryTarget: 'window',
2017-03-10 12:03:36 +01:00
filename: '[name].js',
path: path.resolve(__dirname, 'dist')
2017-03-10 12:41:10 +01:00
},
plugins: [
new UglifyJSPlugin()
]
2017-03-10 12:03:36 +01:00
};