@elliemae/pui-cli 6.3.1 → 6.5.2
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.
- package/lib/lint/lint-staged.config.js +1 -1
- package/lib/webpack/helpers.js +1 -1
- package/lib/webpack/webpack.lib.base.babel.js +24 -34
- package/lib/webpack/webpack.lib.dev.babel.js +0 -2
- package/lib/webpack/webpack.lib.prod.babel.js +0 -2
- package/lib/webpack/webpack.storybook.js +6 -6
- package/package.json +19 -19
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
const path = require('path');
|
|
2
2
|
|
|
3
3
|
module.exports = {
|
|
4
|
+
'*.{js,ts,jsx,tsx,md,mdx,html,css,json}': ['prettier --write'],
|
|
4
5
|
'*.{ts,tsx}': [
|
|
5
6
|
`node ${path.resolve(
|
|
6
7
|
__dirname,
|
|
@@ -12,5 +13,4 @@ module.exports = {
|
|
|
12
13
|
'npm run test:staged',
|
|
13
14
|
'npm run gendoc',
|
|
14
15
|
],
|
|
15
|
-
'*.{js,ts,jsx,tsx,md,mdx,html,css,json}': ['prettier --write'],
|
|
16
16
|
};
|
package/lib/webpack/helpers.js
CHANGED
|
@@ -197,7 +197,7 @@ const getCompressionPlugins = (isLibrary = false) => {
|
|
|
197
197
|
test: /\.(js|css)$/,
|
|
198
198
|
exclude: !isLibrary ? excludeList : [],
|
|
199
199
|
// we are compressing all files since in aws cloudfront edge lambda, we don't want to whitelist files that are not compressed due to below limits
|
|
200
|
-
minRatio:
|
|
200
|
+
minRatio: Infinity,
|
|
201
201
|
};
|
|
202
202
|
return [
|
|
203
203
|
new CompressionPlugin({
|
|
@@ -10,6 +10,7 @@ const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
|
10
10
|
const PostcssPresetEnv = require('postcss-preset-env');
|
|
11
11
|
const DuplicatePackageCheckerPlugin = require('duplicate-package-checker-webpack-plugin');
|
|
12
12
|
const MomentLocalesPlugin = require('moment-locales-webpack-plugin');
|
|
13
|
+
const ResolveTypeScriptPlugin = require('resolve-typescript-plugin');
|
|
13
14
|
const browserslistToEsbuild = require('browserslist-to-esbuild');
|
|
14
15
|
|
|
15
16
|
const {
|
|
@@ -30,28 +31,35 @@ const minicssLoader = {
|
|
|
30
31
|
const finalCSSLoader = (mode) =>
|
|
31
32
|
mode !== 'production' ? { loader: 'style-loader' } : minicssLoader;
|
|
32
33
|
|
|
34
|
+
const copyPluginPatterns = filterByFilePresence([
|
|
35
|
+
{
|
|
36
|
+
from: 'lib/app.config.json',
|
|
37
|
+
to: 'app.config.json',
|
|
38
|
+
noErrorOnMissing: true,
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
from: 'public',
|
|
42
|
+
noErrorOnMissing: true,
|
|
43
|
+
},
|
|
44
|
+
]);
|
|
45
|
+
|
|
33
46
|
const plugins = [
|
|
34
47
|
new EnvironmentPlugin({
|
|
35
|
-
NODE_ENV: 'development',
|
|
36
48
|
ASSET_PATH: '/',
|
|
37
49
|
CI: 'false',
|
|
38
50
|
}),
|
|
39
51
|
new DefinePlugin({
|
|
40
52
|
APP_CONFIG: getAppConfig(true),
|
|
41
53
|
}),
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
noErrorOnMissing: true,
|
|
52
|
-
},
|
|
53
|
-
]),
|
|
54
|
-
}),
|
|
54
|
+
/* eslint-disable indent */
|
|
55
|
+
...(copyPluginPatterns.length > 0
|
|
56
|
+
? [
|
|
57
|
+
new CopyWebpackPlugin({
|
|
58
|
+
patterns: copyPluginPatterns,
|
|
59
|
+
}),
|
|
60
|
+
]
|
|
61
|
+
: []),
|
|
62
|
+
/* eslint-enable indent */
|
|
55
63
|
new DuplicatePackageCheckerPlugin(),
|
|
56
64
|
new LimitChunkCountPlugin({
|
|
57
65
|
maxChunks: 1,
|
|
@@ -102,25 +110,6 @@ module.exports = (options) => ({
|
|
|
102
110
|
},
|
|
103
111
|
},
|
|
104
112
|
},
|
|
105
|
-
{
|
|
106
|
-
test: /\.exec\.js$/,
|
|
107
|
-
exclude: /node_modules/,
|
|
108
|
-
use: [
|
|
109
|
-
{
|
|
110
|
-
loader: 'imports-loader',
|
|
111
|
-
options: {
|
|
112
|
-
wrapper: {
|
|
113
|
-
thisArg: 'window',
|
|
114
|
-
args: {
|
|
115
|
-
module: false,
|
|
116
|
-
exports: false,
|
|
117
|
-
define: false,
|
|
118
|
-
},
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
},
|
|
122
|
-
],
|
|
123
|
-
},
|
|
124
113
|
{
|
|
125
114
|
test: /\.css$/,
|
|
126
115
|
exclude: excludeNodeModulesExcept(modulesToTranspile),
|
|
@@ -191,12 +180,13 @@ module.exports = (options) => ({
|
|
|
191
180
|
plugins: plugins.concat(options.plugins || []),
|
|
192
181
|
resolve: {
|
|
193
182
|
modules: ['node_modules', 'app', 'lib'],
|
|
194
|
-
extensions: ['.
|
|
183
|
+
extensions: ['.ts', '.tsx', '.js', '.jsx', '.json', '.wasm', '.mjs'],
|
|
195
184
|
mainFields: ['browser', 'module', 'main'],
|
|
196
185
|
alias: {
|
|
197
186
|
...getAlias(),
|
|
198
187
|
...((options.resolve || {}).alias || {}),
|
|
199
188
|
},
|
|
189
|
+
plugins: [new ResolveTypeScriptPlugin({})],
|
|
200
190
|
},
|
|
201
191
|
externals: {
|
|
202
192
|
'@elliemae/pui-user-monitoring': 'emuiUserMonitoring',
|
|
@@ -8,7 +8,6 @@ const libraryName = getLibraryName();
|
|
|
8
8
|
module.exports = require('./webpack.lib.base.babel')({
|
|
9
9
|
mode: 'development',
|
|
10
10
|
|
|
11
|
-
// Don't use hashes in dev mode for better performance
|
|
12
11
|
output: {
|
|
13
12
|
filename: `js/${libraryName}.js`,
|
|
14
13
|
chunkFilename: `js/${libraryName}.chunk.js`,
|
|
@@ -25,7 +24,6 @@ module.exports = require('./webpack.lib.base.babel')({
|
|
|
25
24
|
alias: {},
|
|
26
25
|
},
|
|
27
26
|
|
|
28
|
-
// Add development plugins
|
|
29
27
|
plugins: [
|
|
30
28
|
new HtmlWebpackPlugin({
|
|
31
29
|
scriptLoading: 'module',
|
|
@@ -11,7 +11,6 @@ const libraryName = getLibraryName();
|
|
|
11
11
|
module.exports = require('./webpack.lib.base.babel')({
|
|
12
12
|
mode: 'production',
|
|
13
13
|
|
|
14
|
-
// Utilize long-term caching by adding content hashes (not compilation hashes) to compiled assets
|
|
15
14
|
output: {
|
|
16
15
|
filename: `js/${libraryName}.[chunkhash].js`,
|
|
17
16
|
chunkFilename: `js/${libraryName}.[chunkhash].chunk.js`,
|
|
@@ -36,7 +35,6 @@ module.exports = require('./webpack.lib.base.babel')({
|
|
|
36
35
|
},
|
|
37
36
|
|
|
38
37
|
plugins: [
|
|
39
|
-
// Minify and optimize the index.html
|
|
40
38
|
new HtmlWebpackPlugin({
|
|
41
39
|
scriptLoading: 'module',
|
|
42
40
|
template: 'lib/index.pug',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
const
|
|
1
|
+
const { DefinePlugin, EnvironmentPlugin } = require('webpack');
|
|
2
2
|
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
|
|
3
3
|
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
4
|
-
const ResolveTypeScriptPlugin = require('resolve-typescript-plugin')
|
|
4
|
+
const ResolveTypeScriptPlugin = require('resolve-typescript-plugin');
|
|
5
5
|
const {
|
|
6
6
|
getAppConfig,
|
|
7
7
|
isApp,
|
|
@@ -13,10 +13,10 @@ const IS_APP = isApp();
|
|
|
13
13
|
const CWD = process.cwd();
|
|
14
14
|
|
|
15
15
|
const getAdditionalPlugins = () => [
|
|
16
|
-
new
|
|
16
|
+
new DefinePlugin({
|
|
17
17
|
APP_CONFIG: getAppConfig(),
|
|
18
18
|
}),
|
|
19
|
-
new
|
|
19
|
+
new EnvironmentPlugin({
|
|
20
20
|
IS_APP,
|
|
21
21
|
CWD,
|
|
22
22
|
}),
|
|
@@ -37,7 +37,7 @@ const getAdditionalPlugins = () => [
|
|
|
37
37
|
noErrorOnMissing: true,
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
|
-
from: '
|
|
40
|
+
from: 'public',
|
|
41
41
|
noErrorOnMissing: true,
|
|
42
42
|
},
|
|
43
43
|
],
|
|
@@ -74,7 +74,7 @@ exports.webpackFinal = async (config, { configType }) => {
|
|
|
74
74
|
config.resolve.extensions.push('.svg');
|
|
75
75
|
config.resolve.plugins = [
|
|
76
76
|
...(config.resolve.plugins || []),
|
|
77
|
-
new ResolveTypeScriptPlugin(),
|
|
77
|
+
new ResolveTypeScriptPlugin({}),
|
|
78
78
|
];
|
|
79
79
|
config.externals = config.externals || {};
|
|
80
80
|
config.externals['@elliemae/pui-user-monitoring'] = 'emuiUserMonitoring';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/pui-cli",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.5.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "ICE MT UI Platform CLI",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
50
|
"@babel/cli": "~7.17.0",
|
|
51
|
-
"@babel/core": "~7.17.
|
|
51
|
+
"@babel/core": "~7.17.2",
|
|
52
52
|
"@babel/eslint-parser": "~7.17.0",
|
|
53
53
|
"@babel/node": "~7.16.8",
|
|
54
54
|
"@babel/plugin-proposal-class-properties": "~7.16.7",
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
"@babel/preset-env": "~7.16.11",
|
|
63
63
|
"@babel/preset-react": "~7.16.7",
|
|
64
64
|
"@babel/preset-typescript": "~7.16.7",
|
|
65
|
-
"@babel/runtime": "~7.17.
|
|
65
|
+
"@babel/runtime": "~7.17.2",
|
|
66
66
|
"@commitlint/cli": "~16.1.0",
|
|
67
67
|
"@commitlint/config-conventional": "~16.0.0",
|
|
68
68
|
"@elliemae/browserslist-config-elliemae-latest-browsers": "~1.3.0",
|
|
69
|
-
"@faker-js/faker": "6.0.0-alpha.
|
|
69
|
+
"@faker-js/faker": "6.0.0-alpha.6",
|
|
70
70
|
"@pmmmwh/react-refresh-webpack-plugin": "~0.5.4",
|
|
71
71
|
"@semantic-release/changelog": "~6.0.1",
|
|
72
72
|
"@semantic-release/exec": "~6.0.3",
|
|
@@ -84,17 +84,17 @@
|
|
|
84
84
|
"@stylelint/postcss-css-in-js": "~0.37.2",
|
|
85
85
|
"@svgr/webpack": "~6.2.1",
|
|
86
86
|
"@swc/cli": "~0.1.55",
|
|
87
|
-
"@swc/core": "~1.2.
|
|
87
|
+
"@swc/core": "~1.2.138",
|
|
88
88
|
"@swc/jest": "~0.2.17",
|
|
89
89
|
"@testing-library/jest-dom": "~5.16.2",
|
|
90
90
|
"@testing-library/react": "~12.1.2",
|
|
91
91
|
"@testing-library/react-hooks": "~7.0.2",
|
|
92
92
|
"@types/jest": "~27.4.0",
|
|
93
|
-
"@types/node": "~17.0.
|
|
93
|
+
"@types/node": "~17.0.17",
|
|
94
94
|
"@types/rimraf": "~3.0.2",
|
|
95
95
|
"@types/testing-library__jest-dom": "~5.14.2",
|
|
96
|
-
"@typescript-eslint/eslint-plugin": "~5.
|
|
97
|
-
"@typescript-eslint/parser": "~5.
|
|
96
|
+
"@typescript-eslint/eslint-plugin": "~5.11.0",
|
|
97
|
+
"@typescript-eslint/parser": "~5.11.0",
|
|
98
98
|
"autoprefixer": "~10.4.2",
|
|
99
99
|
"axe-core": "~4.4.1",
|
|
100
100
|
"babel-loader": "~8.2.3",
|
|
@@ -128,8 +128,8 @@
|
|
|
128
128
|
"dotenv": "~16.0.0",
|
|
129
129
|
"dotenv-webpack": "~7.1.0",
|
|
130
130
|
"duplicate-package-checker-webpack-plugin": "~3.0.0",
|
|
131
|
-
"enhanced-resolve": "~5.
|
|
132
|
-
"esbuild": "~0.14.
|
|
131
|
+
"enhanced-resolve": "~5.9.0",
|
|
132
|
+
"esbuild": "~0.14.21",
|
|
133
133
|
"esbuild-loader": "~2.18.0",
|
|
134
134
|
"esbuild-plugin-svgr": "~1.0.0",
|
|
135
135
|
"eslint": "~8.8.0",
|
|
@@ -145,7 +145,7 @@
|
|
|
145
145
|
"eslint-plugin-eslint-comments": "~3.2.0",
|
|
146
146
|
"eslint-plugin-import": "~2.25.4",
|
|
147
147
|
"eslint-plugin-jest": "~26.1.0",
|
|
148
|
-
"eslint-plugin-jsdoc": "~37.
|
|
148
|
+
"eslint-plugin-jsdoc": "~37.8.2",
|
|
149
149
|
"eslint-plugin-jsx-a11y": "~6.5.1",
|
|
150
150
|
"eslint-plugin-mdx": "~1.16.0",
|
|
151
151
|
"eslint-plugin-prettier": "~4.0.0",
|
|
@@ -158,7 +158,7 @@
|
|
|
158
158
|
"execa": "~5.1.1",
|
|
159
159
|
"express": "~4.17.2",
|
|
160
160
|
"express-pino-logger": "~7.0.0",
|
|
161
|
-
"express-static-gzip": "~2.1.
|
|
161
|
+
"express-static-gzip": "~2.1.4",
|
|
162
162
|
"favicons": "~6.2.2",
|
|
163
163
|
"favicons-webpack-plugin": "~5.0.2",
|
|
164
164
|
"happy-dom": "~2.31.1",
|
|
@@ -170,7 +170,7 @@
|
|
|
170
170
|
"imports-loader": "~3.1.1",
|
|
171
171
|
"ip": "~1.1.5",
|
|
172
172
|
"jest-axe": "~5.0.1",
|
|
173
|
-
"jest-cli": "~27.5.
|
|
173
|
+
"jest-cli": "~27.5.1",
|
|
174
174
|
"jest-sonar-reporter": "~2.0.0",
|
|
175
175
|
"jest-styled-components": "~7.0.8",
|
|
176
176
|
"jscodeshift": "~0.13.1",
|
|
@@ -184,7 +184,7 @@
|
|
|
184
184
|
"node-gyp": "~8.4.1",
|
|
185
185
|
"node-plop": "~0.30.0",
|
|
186
186
|
"nodemon": "~2.0.15",
|
|
187
|
-
"npm-check-updates": "12.
|
|
187
|
+
"npm-check-updates": "12.3.0",
|
|
188
188
|
"null-loader": "~4.0.1",
|
|
189
189
|
"pino": "~7.6.5",
|
|
190
190
|
"pino-pretty": "~7.5.1",
|
|
@@ -215,19 +215,19 @@
|
|
|
215
215
|
"storybook-builder-vite": "~0.1.15",
|
|
216
216
|
"storybook-react-router": "~1.0.8",
|
|
217
217
|
"style-loader": "~3.3.1",
|
|
218
|
-
"stylelint": "~14.
|
|
219
|
-
"stylelint-config-recommended": "~
|
|
218
|
+
"stylelint": "~14.5.0",
|
|
219
|
+
"stylelint-config-recommended": "~7.0.0",
|
|
220
220
|
"stylelint-config-styled-components": "~0.1.1",
|
|
221
221
|
"swc-loader": "~0.1.15",
|
|
222
222
|
"terser-webpack-plugin": "~5.3.1",
|
|
223
223
|
"ts-node": "~10.5.0",
|
|
224
|
-
"tsc-alias": "~1.
|
|
224
|
+
"tsc-alias": "~1.6.0",
|
|
225
225
|
"typescript": "~4.5.5",
|
|
226
226
|
"update-notifier": "~5.1.0",
|
|
227
227
|
"url-loader": "~4.1.1",
|
|
228
228
|
"uuid": "~8.3.2",
|
|
229
|
-
"vite": "~2.
|
|
230
|
-
"vitest": "~0.2
|
|
229
|
+
"vite": "~2.8.1",
|
|
230
|
+
"vitest": "~0.3.2",
|
|
231
231
|
"webpack": "~5.65.0",
|
|
232
232
|
"webpack-bundle-analyzer": "~4.5.0",
|
|
233
233
|
"webpack-cli": "~4.9.2",
|