How do I use my tsconfig file with ng-packagr?

限于喜欢 提交于 2021-02-10 16:55:30

问题


I'm packaging an Angular 5 library with ng-packagr and I need to use my existing tsconfig.json. I've read the docs here https://github.com/ng-packagr/ng-packagr/blob/master/docs/override-tsconfig.md and it says I need to write a script (I was expecting an option in the config) and pass through the filepath to my tsconfig file.

I don't understand where I write this code? I guess this needs to be an NPM script? The documentation and example seems to be very minimal.

Help with this would be appreciated.


回答1:


I did this by creating a build-package.ts file with the contents (but require not import) then did:

node build-package.ts.



来源:https://stackoverflow.com/questions/52273916/how-do-i-use-my-tsconfig-file-with-ng-packagr

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!