@nx/rspack 22.7.0-beta.4 → 22.7.0-beta.6
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/assets.json
ADDED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nx/rspack",
|
|
3
3
|
"description": "The Nx Plugin for Rspack contains executors and generators that support building applications using Rspack.",
|
|
4
|
-
"version": "22.7.0-beta.
|
|
4
|
+
"version": "22.7.0-beta.6",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -24,10 +24,10 @@
|
|
|
24
24
|
"generators": "./generators.json",
|
|
25
25
|
"executors": "./executors.json",
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@nx/devkit": "22.7.0-beta.
|
|
28
|
-
"@nx/js": "22.7.0-beta.
|
|
29
|
-
"@nx/module-federation": "22.7.0-beta.
|
|
30
|
-
"@nx/web": "22.7.0-beta.
|
|
27
|
+
"@nx/devkit": "22.7.0-beta.6",
|
|
28
|
+
"@nx/js": "22.7.0-beta.6",
|
|
29
|
+
"@nx/module-federation": "22.7.0-beta.6",
|
|
30
|
+
"@nx/web": "22.7.0-beta.6",
|
|
31
31
|
"@phenomnomnominal/tsquery": "~6.1.4",
|
|
32
32
|
"@rspack/core": "1.6.8",
|
|
33
33
|
"@rspack/dev-server": "^1.1.4",
|
|
@@ -57,8 +57,8 @@
|
|
|
57
57
|
"webpack-node-externals": "^3.0.0"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
|
-
"nx": "22.7.0-beta.
|
|
61
|
-
"@nx/nest": "22.7.0-beta.
|
|
60
|
+
"nx": "22.7.0-beta.6",
|
|
61
|
+
"@nx/nest": "22.7.0-beta.6"
|
|
62
62
|
},
|
|
63
63
|
"peerDependencies": {
|
|
64
64
|
"@module-federation/enhanced": "^2.1.0",
|
|
@@ -69,6 +69,5 @@
|
|
|
69
69
|
},
|
|
70
70
|
"publishConfig": {
|
|
71
71
|
"access": "public"
|
|
72
|
-
}
|
|
73
|
-
"types": "./src/index.d.ts"
|
|
72
|
+
}
|
|
74
73
|
}
|
package/project.json
CHANGED
|
@@ -6,33 +6,8 @@
|
|
|
6
6
|
"targets": {
|
|
7
7
|
"build": {
|
|
8
8
|
"outputs": ["{workspaceRoot}/dist/packages/rspack/README.md"],
|
|
9
|
-
"command": "node ./scripts/copy-readme.js rspack"
|
|
10
|
-
|
|
11
|
-
"legacy-post-build": {
|
|
12
|
-
"executor": "@nx/workspace-plugin:legacy-post-build",
|
|
13
|
-
"options": {
|
|
14
|
-
"tsConfig": "./tsconfig.lib.json",
|
|
15
|
-
"assets": [
|
|
16
|
-
"packages/rspack/*.md",
|
|
17
|
-
{
|
|
18
|
-
"input": "./packages/rspack/src",
|
|
19
|
-
"glob": "**/!(*.ts)",
|
|
20
|
-
"output": "./src"
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
"input": "./packages/rspack/src",
|
|
24
|
-
"glob": "**/*.d.ts",
|
|
25
|
-
"output": "./src"
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
"input": "./packages/rspack",
|
|
29
|
-
"glob": "**.json",
|
|
30
|
-
"output": ".",
|
|
31
|
-
"ignore": ["**/tsconfig*.json", "project.json", ".eslintrc.json"]
|
|
32
|
-
},
|
|
33
|
-
"LICENSE"
|
|
34
|
-
]
|
|
35
|
-
}
|
|
9
|
+
"command": "node ./scripts/copy-readme.js rspack",
|
|
10
|
+
"inputs": ["copyReadme"]
|
|
36
11
|
}
|
|
37
12
|
},
|
|
38
13
|
"tags": []
|
|
@@ -1,268 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`convert-to-inferred all projects should migrate all projects using the rspack executors 1`] = `
|
|
4
|
-
"const { NxAppRspackPlugin } = require('@nx/rspack/app-plugin');
|
|
5
|
-
const { NxReactRspackPlugin } = require('@nx/rspack/react-plugin');
|
|
6
|
-
const { useLegacyNxPlugin } = require('@nx/rspack');
|
|
7
|
-
|
|
8
|
-
// These options were migrated by @nx/rspack:convert-to-inferred from
|
|
9
|
-
// the project.json file and merged with the options in this file
|
|
10
|
-
const configValues = {
|
|
11
|
-
build: {
|
|
12
|
-
default: {
|
|
13
|
-
outputPath: '../../dist/apps/app1',
|
|
14
|
-
index: './src/index.html',
|
|
15
|
-
main: './src/main.tsx',
|
|
16
|
-
tsConfig: './tsconfig.app.json',
|
|
17
|
-
assets: ['./src/favicon.ico', './src/assets'],
|
|
18
|
-
styles: ['./src/styles.scss'],
|
|
19
|
-
},
|
|
20
|
-
development: {
|
|
21
|
-
extractLicenses: false,
|
|
22
|
-
optimization: false,
|
|
23
|
-
sourceMap: true,
|
|
24
|
-
vendorChunk: true,
|
|
25
|
-
},
|
|
26
|
-
production: {
|
|
27
|
-
fileReplacements: [
|
|
28
|
-
{
|
|
29
|
-
replace: './src/environments/environment.ts',
|
|
30
|
-
with: './src/environments/environment.prod.ts',
|
|
31
|
-
},
|
|
32
|
-
],
|
|
33
|
-
optimization: true,
|
|
34
|
-
outputHashing: 'all',
|
|
35
|
-
sourceMap: false,
|
|
36
|
-
namedChunks: false,
|
|
37
|
-
extractLicenses: true,
|
|
38
|
-
vendorChunk: false,
|
|
39
|
-
},
|
|
40
|
-
},
|
|
41
|
-
serve: {
|
|
42
|
-
default: {
|
|
43
|
-
hmr: true,
|
|
44
|
-
server: {
|
|
45
|
-
type: 'https',
|
|
46
|
-
options: { cert: './server.crt', key: './server.key' },
|
|
47
|
-
},
|
|
48
|
-
port: 4200,
|
|
49
|
-
headers: { 'Access-Control-Allow-Origin': '*' },
|
|
50
|
-
historyApiFallback: {
|
|
51
|
-
index: '/index.html',
|
|
52
|
-
disableDotRule: true,
|
|
53
|
-
htmlAcceptHeaders: ['text/html', 'application/xhtml+xml'],
|
|
54
|
-
},
|
|
55
|
-
},
|
|
56
|
-
development: { open: true },
|
|
57
|
-
production: { hmr: false },
|
|
58
|
-
},
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
// Determine the correct configValue to use based on the configuration
|
|
62
|
-
const configuration = process.env.NX_TASK_TARGET_CONFIGURATION || 'default';
|
|
63
|
-
|
|
64
|
-
const buildOptions = {
|
|
65
|
-
...configValues.build.default,
|
|
66
|
-
...configValues.build[configuration],
|
|
67
|
-
};
|
|
68
|
-
const devServerOptions = {
|
|
69
|
-
...configValues.serve.default,
|
|
70
|
-
...configValues.serve[configuration],
|
|
71
|
-
};
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* @type{import('@rspack/core').RspackOptionsNormalized}
|
|
75
|
-
*/
|
|
76
|
-
module.exports = async () => ({
|
|
77
|
-
devServer: devServerOptions,
|
|
78
|
-
plugins: [
|
|
79
|
-
new NxAppRspackPlugin(buildOptions),
|
|
80
|
-
new NxReactRspackPlugin({
|
|
81
|
-
// Uncomment this line if you don't want to use SVGR
|
|
82
|
-
// See: https://react-svgr.com/
|
|
83
|
-
// svgr: false
|
|
84
|
-
}),
|
|
85
|
-
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
86
|
-
await useLegacyNxPlugin(require('./rspack.config.old'), buildOptions),
|
|
87
|
-
],
|
|
88
|
-
});
|
|
89
|
-
"
|
|
90
|
-
`;
|
|
91
|
-
|
|
92
|
-
exports[`convert-to-inferred all projects should migrate all projects using the rspack executors 2`] = `
|
|
93
|
-
"const { NxAppRspackPlugin } = require('@nx/rspack/app-plugin');
|
|
94
|
-
const { NxReactRspackPlugin } = require('@nx/rspack/react-plugin');
|
|
95
|
-
const { useLegacyNxPlugin } = require('@nx/rspack');
|
|
96
|
-
|
|
97
|
-
// These options were migrated by @nx/rspack:convert-to-inferred from
|
|
98
|
-
// the project.json file and merged with the options in this file
|
|
99
|
-
const configValues = {
|
|
100
|
-
build: {
|
|
101
|
-
default: {
|
|
102
|
-
outputPath: '../../dist/apps/app2',
|
|
103
|
-
index: './src/index.html',
|
|
104
|
-
main: './src/main.tsx',
|
|
105
|
-
tsConfig: './tsconfig.app.json',
|
|
106
|
-
assets: ['./src/favicon.ico', './src/assets'],
|
|
107
|
-
styles: ['./src/styles.scss'],
|
|
108
|
-
},
|
|
109
|
-
development: {
|
|
110
|
-
extractLicenses: false,
|
|
111
|
-
optimization: false,
|
|
112
|
-
sourceMap: true,
|
|
113
|
-
vendorChunk: true,
|
|
114
|
-
},
|
|
115
|
-
production: {
|
|
116
|
-
fileReplacements: [
|
|
117
|
-
{
|
|
118
|
-
replace: './src/environments/environment.ts',
|
|
119
|
-
with: './src/environments/environment.prod.ts',
|
|
120
|
-
},
|
|
121
|
-
],
|
|
122
|
-
optimization: true,
|
|
123
|
-
outputHashing: 'all',
|
|
124
|
-
sourceMap: false,
|
|
125
|
-
namedChunks: false,
|
|
126
|
-
extractLicenses: true,
|
|
127
|
-
vendorChunk: false,
|
|
128
|
-
},
|
|
129
|
-
},
|
|
130
|
-
serve: {
|
|
131
|
-
default: {
|
|
132
|
-
hmr: true,
|
|
133
|
-
server: {
|
|
134
|
-
type: 'https',
|
|
135
|
-
options: { cert: './server.crt', key: './server.key' },
|
|
136
|
-
},
|
|
137
|
-
port: 4200,
|
|
138
|
-
headers: { 'Access-Control-Allow-Origin': '*' },
|
|
139
|
-
historyApiFallback: {
|
|
140
|
-
index: '/index.html',
|
|
141
|
-
disableDotRule: true,
|
|
142
|
-
htmlAcceptHeaders: ['text/html', 'application/xhtml+xml'],
|
|
143
|
-
},
|
|
144
|
-
},
|
|
145
|
-
development: { open: true },
|
|
146
|
-
production: { hmr: false },
|
|
147
|
-
},
|
|
148
|
-
};
|
|
149
|
-
|
|
150
|
-
// Determine the correct configValue to use based on the configuration
|
|
151
|
-
const configuration = process.env.NX_TASK_TARGET_CONFIGURATION || 'default';
|
|
152
|
-
|
|
153
|
-
const buildOptions = {
|
|
154
|
-
...configValues.build.default,
|
|
155
|
-
...configValues.build[configuration],
|
|
156
|
-
};
|
|
157
|
-
const devServerOptions = {
|
|
158
|
-
...configValues.serve.default,
|
|
159
|
-
...configValues.serve[configuration],
|
|
160
|
-
};
|
|
161
|
-
|
|
162
|
-
/**
|
|
163
|
-
* @type{import('@rspack/core').RspackOptionsNormalized}
|
|
164
|
-
*/
|
|
165
|
-
module.exports = async () => ({
|
|
166
|
-
devServer: devServerOptions,
|
|
167
|
-
plugins: [
|
|
168
|
-
new NxAppRspackPlugin(buildOptions),
|
|
169
|
-
new NxReactRspackPlugin({
|
|
170
|
-
// Uncomment this line if you don't want to use SVGR
|
|
171
|
-
// See: https://react-svgr.com/
|
|
172
|
-
// svgr: false
|
|
173
|
-
}),
|
|
174
|
-
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
175
|
-
await useLegacyNxPlugin(require('./rspack.config.old'), buildOptions),
|
|
176
|
-
],
|
|
177
|
-
});
|
|
178
|
-
"
|
|
179
|
-
`;
|
|
180
|
-
|
|
181
|
-
exports[`convert-to-inferred all projects should migrate all projects using the rspack executors 3`] = `
|
|
182
|
-
"const { NxAppRspackPlugin } = require('@nx/rspack/app-plugin');
|
|
183
|
-
const { NxReactRspackPlugin } = require('@nx/rspack/react-plugin');
|
|
184
|
-
const { useLegacyNxPlugin } = require('@nx/rspack');
|
|
185
|
-
|
|
186
|
-
// These options were migrated by @nx/rspack:convert-to-inferred from
|
|
187
|
-
// the project.json file and merged with the options in this file
|
|
188
|
-
const configValues = {
|
|
189
|
-
build: {
|
|
190
|
-
default: {
|
|
191
|
-
outputPath: '../../dist/apps/app3',
|
|
192
|
-
index: './src/index.html',
|
|
193
|
-
main: './src/main.tsx',
|
|
194
|
-
tsConfig: './tsconfig.app.json',
|
|
195
|
-
assets: ['./src/favicon.ico', './src/assets'],
|
|
196
|
-
styles: ['./src/styles.scss'],
|
|
197
|
-
},
|
|
198
|
-
development: {
|
|
199
|
-
extractLicenses: false,
|
|
200
|
-
optimization: false,
|
|
201
|
-
sourceMap: true,
|
|
202
|
-
vendorChunk: true,
|
|
203
|
-
},
|
|
204
|
-
production: {
|
|
205
|
-
fileReplacements: [
|
|
206
|
-
{
|
|
207
|
-
replace: './src/environments/environment.ts',
|
|
208
|
-
with: './src/environments/environment.prod.ts',
|
|
209
|
-
},
|
|
210
|
-
],
|
|
211
|
-
optimization: true,
|
|
212
|
-
outputHashing: 'all',
|
|
213
|
-
sourceMap: false,
|
|
214
|
-
namedChunks: false,
|
|
215
|
-
extractLicenses: true,
|
|
216
|
-
vendorChunk: false,
|
|
217
|
-
},
|
|
218
|
-
},
|
|
219
|
-
serve: {
|
|
220
|
-
default: {
|
|
221
|
-
hmr: true,
|
|
222
|
-
server: {
|
|
223
|
-
type: 'https',
|
|
224
|
-
options: { cert: './server.crt', key: './server.key' },
|
|
225
|
-
},
|
|
226
|
-
port: 4200,
|
|
227
|
-
headers: { 'Access-Control-Allow-Origin': '*' },
|
|
228
|
-
historyApiFallback: {
|
|
229
|
-
index: '/index.html',
|
|
230
|
-
disableDotRule: true,
|
|
231
|
-
htmlAcceptHeaders: ['text/html', 'application/xhtml+xml'],
|
|
232
|
-
},
|
|
233
|
-
},
|
|
234
|
-
development: { open: true },
|
|
235
|
-
production: { hmr: false },
|
|
236
|
-
},
|
|
237
|
-
};
|
|
238
|
-
|
|
239
|
-
// Determine the correct configValue to use based on the configuration
|
|
240
|
-
const configuration = process.env.NX_TASK_TARGET_CONFIGURATION || 'default';
|
|
241
|
-
|
|
242
|
-
const buildOptions = {
|
|
243
|
-
...configValues.build.default,
|
|
244
|
-
...configValues.build[configuration],
|
|
245
|
-
};
|
|
246
|
-
const devServerOptions = {
|
|
247
|
-
...configValues.serve.default,
|
|
248
|
-
...configValues.serve[configuration],
|
|
249
|
-
};
|
|
250
|
-
|
|
251
|
-
/**
|
|
252
|
-
* @type{import('@rspack/core').RspackOptionsNormalized}
|
|
253
|
-
*/
|
|
254
|
-
module.exports = async () => ({
|
|
255
|
-
devServer: devServerOptions,
|
|
256
|
-
plugins: [
|
|
257
|
-
new NxAppRspackPlugin(buildOptions),
|
|
258
|
-
new NxReactRspackPlugin({
|
|
259
|
-
// Uncomment this line if you don't want to use SVGR
|
|
260
|
-
// See: https://react-svgr.com/
|
|
261
|
-
// svgr: false
|
|
262
|
-
}),
|
|
263
|
-
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
264
|
-
await useLegacyNxPlugin(require('./rspack.config.old'), buildOptions),
|
|
265
|
-
],
|
|
266
|
-
});
|
|
267
|
-
"
|
|
268
|
-
`;
|