Skip to content

Commit 68b51e8

Browse files
Timeless0911fi3ework
authored andcommitted
chore: update
1 parent f6f03c1 commit 68b51e8

File tree

2 files changed

+39
-0
lines changed

2 files changed

+39
-0
lines changed

packages/core/tests/__snapshots__/config.test.ts.snap

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,16 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
122122
"web",
123123
],
124124
},
125+
{
126+
"resolve": {
127+
"extensionAlias": {
128+
".js": [
129+
".ts",
130+
".tsx",
131+
],
132+
},
133+
},
134+
},
125135
],
126136
},
127137
},
@@ -235,6 +245,16 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
235245
"web",
236246
],
237247
},
248+
{
249+
"resolve": {
250+
"extensionAlias": {
251+
".js": [
252+
".ts",
253+
".tsx",
254+
],
255+
},
256+
},
257+
},
238258
],
239259
},
240260
},
@@ -342,6 +362,16 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
342362
"web",
343363
],
344364
},
365+
{
366+
"resolve": {
367+
"extensionAlias": {
368+
".js": [
369+
".ts",
370+
".tsx",
371+
],
372+
},
373+
},
374+
},
345375
],
346376
},
347377
},

packages/core/tests/config.test.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,15 @@ describe('Should compose create Rsbuild config correctly', () => {
179179
output: {
180180
filenameHash: false,
181181
},
182+
tools: {
183+
rspack: {
184+
resolve: {
185+
extensionAlias: {
186+
'.js': ['.ts', '.tsx'],
187+
},
188+
},
189+
},
190+
},
182191
};
183192
const composedRsbuildConfig = await composeCreateRsbuildConfig(
184193
rslibConfig,

0 commit comments

Comments
 (0)