Preventing tsc compiler from omitting the unnecessary external modules

后端 未结 2 923
谎友^
谎友^ 2021-01-16 05:25

There\'s a feature in TypeScript which I like so much and that\'s external modules using RequireJs and that the fact that the compiler won\'t include imported modules unless

2条回答
  •  暖寄归人
    2021-01-16 06:15

    Another way to do it:

    /// 
    import A = require('./A');
    

    No need to create fictitious code

提交回复
热议问题