Reputation: 7432
As far as I can understand, I cannot have the Typescript settings in Visual Studio to generate separate .js files for each .ts file and at the same time generate ONE merged .d.ts file.
With the current settings, both the .js and the .d.ts are either merged or separate.
Am I missing some obvious setting?
Upvotes: 1
Views: 458
Reputation: 48
Have you seen dts-bundle? You can use this to generate a single .d.ts
file which contains an external module. You can then distribute the generated definition file alongside your transpiled library code, so that consuming typescript applications have access to the type definitions of your library.
Upvotes: 1