You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
779 B
JavaScript
37 lines
779 B
JavaScript
const UmdPlugin = require('./plugins/umd');
|
|
|
|
module.exports = {
|
|
entry: './src/quagga.ts',
|
|
devtool: 'inline-source-map',
|
|
mode: 'development',
|
|
module: {
|
|
rules: [{
|
|
test: /\.(js|ts)$/,
|
|
exclude: /node_modules/,
|
|
loader: 'babel-loader'
|
|
}]
|
|
},
|
|
output: {
|
|
path: __dirname + '/dist',
|
|
publicPath: '/',
|
|
filename: 'quagga.js',
|
|
library: 'Quagga',
|
|
libraryTarget: 'var',
|
|
umdNamedDefine: true
|
|
},
|
|
plugins: [
|
|
new UmdPlugin()
|
|
],
|
|
resolve: {
|
|
extensions: ['.js', '.ts'],
|
|
alias: {
|
|
'./config/config': './config/config.dev'
|
|
}
|
|
},
|
|
target: 'web',
|
|
devServer: {
|
|
contentBase: './',
|
|
hot: true
|
|
}
|
|
};
|