Commit 490d0c8
committed
fix: detect TS >= 5.4 across major versions
The previous regex /^[5-9]\.([4-9]|[1-9]\d)/ only matched X.4 and above
within each major, so TypeScript 6.0–6.3 fell through to the legacy
require()-based loader — which returns moduleResolution as a raw string
and reproduces #52 on the very versions this PR targets. Switch to a
numeric major/minor comparison.1 parent 628c8df commit 490d0c8
3 files changed
Lines changed: 19 additions & 17 deletions
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 | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
40 | | - | |
| 40 | + | |
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
21 | 23 | | |
22 | 24 | | |
23 | 25 | | |
| |||
0 commit comments