Commit 78efcf9
fix: export missing shared types to prevent TS2742 in consumer projects (#2586)
Types like `DataOrientation`, `Direction`, `StringOrNumber`, etc. are used
in public component prop interfaces (e.g. `SeparatorProps`, `TabsRootProps`)
but were not re-exported from the main `index.ts` entry point. The bundler's
chunk splitting placed them in an internal chunk (`index3`), which is not
listed in the package `exports` map. This caused TS2742 errors in consumer
projects using `vue-tsc` with `declaration: true`:
error TS2742: The inferred type of '__VLS_export' cannot be named without
a reference to 'reka-ui/dist/index3'. This is likely not portable.
Re-exporting these types from `src/index.ts` ensures they are included in
the main `index.d.ts` declaration file, making them resolvable without
referencing internal chunks.
Co-authored-by: YKDZ <noreply@github.com>1 parent 9ad6ec0 commit 78efcf9
1 file changed
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
99 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
100 | 107 | | |
101 | 108 | | |
102 | 109 | | |
| |||
0 commit comments