@meteorjs/rspack 0.1.3 → 0.1.4
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/package.json +1 -1
- package/rspack.config.js +19 -15
package/package.json
CHANGED
package/rspack.config.js
CHANGED
|
@@ -226,6 +226,7 @@ module.exports = async function (inMeteor = {}, argv = {}) {
|
|
|
226
226
|
const projectDir = process.cwd();
|
|
227
227
|
const projectConfigPath = Meteor.projectConfigPath || path.resolve(projectDir, 'rspack.config.js');
|
|
228
228
|
const configPath = Meteor.configPath;
|
|
229
|
+
const testEntry = Meteor.testEntry;
|
|
229
230
|
|
|
230
231
|
const isTypescriptEnabled = Meteor.isTypescriptEnabled || false;
|
|
231
232
|
const isJsxEnabled =
|
|
@@ -409,26 +410,27 @@ module.exports = async function (inMeteor = {}, argv = {}) {
|
|
|
409
410
|
]
|
|
410
411
|
: [];
|
|
411
412
|
|
|
412
|
-
|
|
413
413
|
const clientEntry =
|
|
414
414
|
isTest && isTestEager && isTestFullApp
|
|
415
415
|
? generateEagerTestFile({
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
416
|
+
isAppTest: true,
|
|
417
|
+
projectDir,
|
|
418
|
+
buildContext,
|
|
419
|
+
ignoreEntries: [...meteorIgnoreEntries, "**/server/**"],
|
|
420
|
+
prefix: "client",
|
|
421
|
+
})
|
|
422
422
|
: isTest && isTestEager
|
|
423
|
-
|
|
423
|
+
? generateEagerTestFile({
|
|
424
424
|
isAppTest: false,
|
|
425
425
|
isClient: true,
|
|
426
426
|
projectDir,
|
|
427
427
|
buildContext,
|
|
428
|
-
ignoreEntries: [...meteorIgnoreEntries,
|
|
429
|
-
prefix:
|
|
428
|
+
ignoreEntries: [...meteorIgnoreEntries, "**/server/**"],
|
|
429
|
+
prefix: "client",
|
|
430
430
|
})
|
|
431
|
-
|
|
431
|
+
: isTest
|
|
432
|
+
? path.resolve(process.cwd(), testEntry)
|
|
433
|
+
: path.resolve(process.cwd(), buildContext, entryPath);
|
|
432
434
|
const clientNameConfig = `[${(isTest && 'test-') || ''}client-rspack]`;
|
|
433
435
|
// Base client config
|
|
434
436
|
let clientConfig = {
|
|
@@ -530,17 +532,19 @@ module.exports = async function (inMeteor = {}, argv = {}) {
|
|
|
530
532
|
isAppTest: true,
|
|
531
533
|
projectDir,
|
|
532
534
|
buildContext,
|
|
533
|
-
ignoreEntries: [...meteorIgnoreEntries,
|
|
534
|
-
prefix:
|
|
535
|
+
ignoreEntries: [...meteorIgnoreEntries, "**/client/**"],
|
|
536
|
+
prefix: "server",
|
|
535
537
|
})
|
|
536
538
|
: isTest && isTestEager
|
|
537
539
|
? generateEagerTestFile({
|
|
538
540
|
isAppTest: false,
|
|
539
541
|
projectDir,
|
|
540
542
|
buildContext,
|
|
541
|
-
ignoreEntries: [...meteorIgnoreEntries,
|
|
542
|
-
prefix:
|
|
543
|
+
ignoreEntries: [...meteorIgnoreEntries, "**/client/**"],
|
|
544
|
+
prefix: "server",
|
|
543
545
|
})
|
|
546
|
+
: isTest
|
|
547
|
+
? path.resolve(process.cwd(), testEntry)
|
|
544
548
|
: path.resolve(projectDir, buildContext, entryPath);
|
|
545
549
|
const serverNameConfig = `[${(isTest && 'test-') || ''}server-rspack]`;
|
|
546
550
|
// Base server config
|