-
Notifications
You must be signed in to change notification settings - Fork 1.1k
/
webpack.config.js
30 lines (28 loc) · 981 Bytes
/
webpack.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
const path = require('path');
const CopyPlugin = require("copy-webpack-plugin");
module.exports = env => {
return {
entry: ['./index.js'],
devtool: env && env.production ? 'none' : 'source-map',
resolve: {
extensions: ['.js'],
},
experiments: {
outputModule: true
},
output: {
filename: 'elsa-workflows-designer.js',
path: path.resolve(__dirname, 'wwwroot'),
libraryTarget: 'module'
},
plugins: [
new CopyPlugin({
patterns: [
{ from: "node_modules/@elsa-workflows/elsa-workflows-designer/dist/elsa-workflows-designer", to: "elsa-workflows-designer" },
{ from: "node_modules/monaco-editor/min", to: "monaco-editor/min" },
{ from: "node_modules/monaco-editor/min-maps", to: "monaco-editor/min-maps" },
],
}),
],
};
};