@hmcts/ccd-case-ui-toolkit 5.0.0-angular11-upgrade → 5.0.1-angular11-upgrade

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,98 +0,0 @@
1
- const fs = require('fs');
2
- const path = require('path');
3
- const TerserPlugin = require('terser-webpack-plugin');
4
- const angularExternals = require('webpack-angular-externals');
5
- const rxjsExternals = require('webpack-rxjs-externals');
6
- const webpack = require('webpack');
7
- const pkg = JSON.parse(fs.readFileSync('./package.json').toString());
8
-
9
- module.exports = {
10
- mode: 'production',
11
- target: "node",
12
- entry: {
13
- 'index.umd': './src/index.ts',
14
- 'index.umd.min': './src/index.ts',
15
- },
16
- output: {
17
- path: path.join(__dirname, 'dist'),
18
- filename: '[name].js',
19
- libraryTarget: 'umd',
20
- library: 'case-ui-toolkit'
21
- },
22
- resolve: {
23
- extensions: [ '.ts', '.js', '.json' ]
24
- },
25
- externals: [
26
- angularExternals(),
27
- rxjsExternals()
28
- ],
29
- devtool: 'source-map',
30
- optimization: {
31
- minimize: true,
32
- minimizer: [new TerserPlugin ({
33
- terserOptions: {
34
- sourceMap: true,
35
- compress: true
36
- },
37
- include: /\.min\.js$/,
38
- })]
39
- },
40
- module: {
41
- rules: [
42
- {
43
- test: /\.ts$/,
44
- use: [
45
- {
46
- loader: 'ts-loader',
47
- },
48
- {
49
- loader: 'angular2-template-loader'
50
- }
51
- ],
52
- exclude: [
53
- /node_modules/,
54
- /\.(spec|e2e)\.ts$/
55
- ]
56
- },
57
-
58
- {
59
- test: /\.json$/,
60
- use: 'json-loader'
61
- },
62
-
63
- {
64
- test: /\.css$/,
65
- use: ['to-string-loader', 'css-loader']
66
- },
67
-
68
- {
69
- test: /\.scss$/,
70
- use: ['to-string-loader', 'css-loader', 'sass-loader']
71
- },
72
-
73
- {
74
- test: /\.html$/,
75
- use: 'raw-loader'
76
- }
77
- ]
78
- },
79
- plugins: [
80
- new webpack.ContextReplacementPlugin(
81
- /angular(\\|\/)core(\\|\/)@angular/,
82
- path.join(__dirname, 'src')
83
- ),
84
- new webpack.BannerPlugin({
85
- banner: `
86
- /**
87
- * ${pkg.name} - ${pkg.description}
88
- * @version v${pkg.version}
89
- * @link ${pkg.homepage}
90
- * @license ${pkg.license}
91
- */
92
- `.trim(),
93
- raw: true,
94
- entryOnly: true
95
- })
96
-
97
- ]
98
- };