@meteorjs/rspack 0.1.4 → 0.1.5

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/rspack.config.js +8 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meteorjs/rspack",
3
- "version": "0.1.4",
3
+ "version": "0.1.5",
4
4
  "description": "Configuration logic for using Rspack in Meteor projects",
5
5
  "main": "index.js",
6
6
  "type": "commonjs",
package/rspack.config.js CHANGED
@@ -227,6 +227,8 @@ module.exports = async function (inMeteor = {}, argv = {}) {
227
227
  const projectConfigPath = Meteor.projectConfigPath || path.resolve(projectDir, 'rspack.config.js');
228
228
  const configPath = Meteor.configPath;
229
229
  const testEntry = Meteor.testEntry;
230
+ const testClientEntry = Meteor.testClientEntry;
231
+ const testServerEntry = Meteor.testServerEntry;
230
232
 
231
233
  const isTypescriptEnabled = Meteor.isTypescriptEnabled || false;
232
234
  const isJsxEnabled =
@@ -428,8 +430,10 @@ module.exports = async function (inMeteor = {}, argv = {}) {
428
430
  ignoreEntries: [...meteorIgnoreEntries, "**/server/**"],
429
431
  prefix: "client",
430
432
  })
431
- : isTest
433
+ : isTest && testEntry
432
434
  ? path.resolve(process.cwd(), testEntry)
435
+ : isTest && testClientEntry
436
+ ? path.resolve(process.cwd(), testClientEntry)
433
437
  : path.resolve(process.cwd(), buildContext, entryPath);
434
438
  const clientNameConfig = `[${(isTest && 'test-') || ''}client-rspack]`;
435
439
  // Base client config
@@ -543,8 +547,10 @@ module.exports = async function (inMeteor = {}, argv = {}) {
543
547
  ignoreEntries: [...meteorIgnoreEntries, "**/client/**"],
544
548
  prefix: "server",
545
549
  })
546
- : isTest
550
+ : isTest && testEntry
547
551
  ? path.resolve(process.cwd(), testEntry)
552
+ : isTest && testServerEntry
553
+ ? path.resolve(process.cwd(), testServerEntry)
548
554
  : path.resolve(projectDir, buildContext, entryPath);
549
555
  const serverNameConfig = `[${(isTest && 'test-') || ''}server-rspack]`;
550
556
  // Base server config