Gre*_*man 6 javascript typescript systemjs aurelia
我正在尝试让TypeScript使用默认的Aurelia骨架,它基于System.JS作为加载器.
我无法让TypeScript接受模块导入.我将其中一个骨架文件"nav-bar.js"重命名为"nav-bar.ts",看看我是否可以将该示例转换为TypeScript.代码导致编译器错误:"错误:(5,24)TS2307:找不到外部模块'aurelia-framework'."
import {bindable} from "aurelia-framework";
export class NavBar {
//noinspection ES6Validation
@bindable router = null;
}
Run Code Online (Sandbox Code Playgroud)
如何让TypeScript将aurelia-framework视为有效的导入?在项目的根目录中有一个名为config.js的文件似乎描述了"aurelia-framework"的具体位置,但TypeScript不知道如何加载它.
在此先感谢您的帮助.