Repository navigation
Commit 4932904
committed
fix(dts-generator): fix runCheck for TS6 compatibility
TS6 introduced three breaking changes that affected runCheck:
1. moduleResolution "Node16" rejects bare-specifier ambient module
declarations (declare module "sap/ui/core/Control") — switched to
module: ESNext + moduleResolution: Bundler which supports them.
2. The default types list is now empty, so @types packages are no
longer auto-included — added discovery logic that reads declared
@types/* from the nearest package.json and walks up from CWD to
locate them in potentially hoisted node_modules directories.
3. In monorepo/workspace setups the walk-up could find unrelated
@types packages (e.g. @types/openui5) that conflict with the .d.ts
files being checked — scoped discovery to only declared dependencies.1 parent 35b99d5 commit 4932904
1 file changed
Lines changed: 51 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
51 | 98 | | |
52 | 99 | | |
53 | 100 | | |
| |||
56 | 103 | | |
57 | 104 | | |
58 | 105 | | |
59 | | - | |
60 | | - | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
61 | 109 | | |
62 | 110 | | |
63 | 111 | | |
| |||
0 commit comments