Repository navigation
Commit d1b5b6d
authored
fix: resolve aliases pointing at a package directory ending in .js (#21542)
* fix: resolve aliases pointing at a package directory ending in .js
The `.js` -> `.ts` extensionAlias that `experiments.typescript` installs made
`ExtensionAliasPlugin` resolve such a request as an exact file only, so a
package directory named `pkg.js` became unreachable. Fixed in enhanced-resolve
(webpack/enhanced-resolve#641); take the release and add a regression test.
* test: pin the extensionAlias in the regression case
Relying on the `experiments.typescript` "auto" default made the case a no-op
below Node.js 22.6, where the alias is never installed.
* build: lock enhanced-resolve 5.24.41 parent 9cdcc57 commit d1b5b6d
7 files changed
Lines changed: 50 additions & 2 deletions
File tree
- .changeset
- test/configCases/typescript/alias-to-package-directory
- node_modules/pkg.js
- lib
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
| 108 | + | |
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4288 | 4288 | | |
4289 | 4289 | | |
4290 | 4290 | | |
4291 | | - | |
| 4291 | + | |
4292 | 4292 | | |
4293 | 4293 | | |
4294 | 4294 | | |
4295 | 4295 | | |
4296 | 4296 | | |
4297 | 4297 | | |
4298 | 4298 | | |
| 4299 | + | |
| 4300 | + | |
| 4301 | + | |
| 4302 | + | |
| 4303 | + | |
| 4304 | + | |
| 4305 | + | |
| 4306 | + | |
4299 | 4307 | | |
4300 | 4308 | | |
4301 | 4309 | | |
| |||
0 commit comments