shlomiassaf / angular-library-starter

Your last library starter. A complete, @angular grade, library starter
MIT License
44 stars 12 forks source link

support custom typings.d.ts #12

Open emazv72 opened 7 years ago

emazv72 commented 7 years ago

Note: for support questions, please use one of these channels: Chat: AngularClass.slack or Twitter: @AngularClass

Feature

Adding a custom my-lib/src/typings.d.ts is ignored during sequence !build:webpack

Looks like it's a configuration issue inside tsconfig.package.json. Might create a PR if I could understand better the webpack generation logic.

Thanks Emanuele

shlomiassaf commented 7 years ago

The recent commit should fix some issues with it however you will have to import it manually with the triple slash typescript directive.

Auto loading d.ts files might crete serious issues with duplications so I don't suggest doing so.

Also, remember that if you are planning on using that custom typings as public API you will need to find a different approach and expose those types not as augmented module but as a regular ts module.