32 lines
780 B
JavaScript
32 lines
780 B
JavaScript
const path = require('path');
|
|
|
|
module.exports = {
|
|
mode: 'production',
|
|
devtool: 'nosources-source-map',
|
|
entry: './src/index.js',
|
|
externals: ['lodash'],
|
|
output: {
|
|
path: path.resolve(__dirname, 'dist'),
|
|
filename: 'jbase62.js',
|
|
library: "JBase62",
|
|
libraryExport: 'default',
|
|
libraryTarget: 'umd',
|
|
},
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.js$/,
|
|
exclude: /node_modules/,
|
|
use: {
|
|
loader: 'babel-loader',
|
|
options: {
|
|
presets: ['@babel/preset-env'],
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
externals: {
|
|
'lodash': '_',
|
|
}
|
|
}; |