-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathwebpack.config.mjs
More file actions
54 lines (52 loc) · 1.27 KB
/
Copy pathwebpack.config.mjs
File metadata and controls
54 lines (52 loc) · 1.27 KB
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import * as path from 'path';
import { fileURLToPath } from 'url';
const __dirname = path.dirname(fileURLToPath(import.meta.url));
export default {
target: 'node',
entry: './src/index.ts',
devtool: 'source-map',
mode: 'production',
output: {
filename: 'index.js',
path: path.resolve(__dirname, 'dist'),
libraryTarget: 'commonjs2',
},
resolve: {
extensions: ['.ts', '.js', '.json'],
},
module: {
rules: [
{
test: /\.ts$/,
use: 'ts-loader',
exclude: /node_modules/,
},
{
test: /\.scss$/,
use: ['style-loader', 'css-loader', 'sass-loader'],
},
{
test: /\.css$/,
use: ['style-loader', 'css-loader'],
},
],
},
externals: [
'tabby-core',
'tabby-terminal',
'tabby-settings',
'@angular/core',
'@angular/common',
'@angular/forms',
'@angular/animations',
'@angular/platform-browser',
'@ng-bootstrap/ng-bootstrap',
'rxjs',
'rxjs/operators',
/^@angular\/.*/,
/^tabby-.*/,
],
optimization: {
minimize: false,
},
};