teambit / bit

A build system for development of composable software.
https://bit.dev
Other
17.91k stars 929 forks source link

feat(compile), introduce --generate-types flag #9308

Closed davidfirst closed 3 days ago

davidfirst commented 6 days ago

Currently, d.ts files are generated during build on the capsules only. Not in the workspace. Mainly due to performance issues. To generate d.ts files, typescript needs a wider context than a single file. This flag introduces the ability to generate these d.ts file. In some cases they're needed even though it makes the compilation much slower.

The implementation of the typescript's end is done here: https://bit.cloud/teambit/typescript/~change-requests/generate-types-on-workspace