Closed avin-kavish closed 2 years ago
This is actually problem for front-end code, affects bundle size.
This is added to each root/entry file.
If you configure your tsconfig like include: "**/*.ts"
, all the matched files are meant as root files. Each of that file can be root/entry file. So it is important to add that to each such file.
If you change the include to "index.ts"
, TS knows this is only root/entry file, and it will follow imports to find all other application files.
I can add new option to config: rootFiles: string[]
.
So it is important to add that to each such file.
why? The library is only needed when used
Fixed in v1. Not in the current version.
and not just the ones that use it