Import js file with TypeScript 2.0

后端 未结 2 1201
清歌不尽
清歌不尽 2021-02-12 21:54

Abstract

I\'m trying to import \".js\" file from an external location (i.e. node_modules) I\'m trying to do this using commonjs module pattern, howeve

2条回答
  •  粉色の甜心
    2021-02-12 22:02

    being able to define it's ".d.ts" declarations while having both files located in different locations.

    import follows the same module resolution process when given a .js or .d.ts file with relative files.

提交回复
热议问题