forked from sourcygen/electron-angular-quick-start
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebpack.main.config.js
More file actions
34 lines (33 loc) · 841 Bytes
/
webpack.main.config.js
File metadata and controls
34 lines (33 loc) · 841 Bytes
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
31
32
33
34
const path = require('path');
const CopyWebpackPlugin = require('copy-webpack-plugin');
module.exports = {
/**
* This is the main entry point for your application, it's the first file
* that runs in the main process.
*/
entry: './workspaces/electron-app/main/index.ts',
// Put your normal webpack config below here
module: {
rules: require('./webpack.rules'),
},
resolve: {
extensions: ['.js', '.ts', '.jsx', '.tsx', '.css', '.json'],
modules: [path.resolve(__dirname, 'node_modules'), 'node_modules'],
},
node: {
__filename: false,
__dirname: false,
},
plugins: [
new CopyWebpackPlugin({
patterns: [
{ from: 'workspaces/electron-app/main/assets' },
{
from: 'workspaces/angular-app/.dist/angular-app',
to: '../renderer/angular_window',
noErrorOnMissing: true,
},
],
}),
],
};