Update tsconfig.json
Now that Angular 2 and its dependencies are installed, we need to enable TypeScript’s experimental support for decorators and include the es6-shim typings. In the future decorators and ES6 will be the default and these settings will not be needed. Add "experimentalDecorators": true, "emitDecoratorMetadata": true
to the "compilerOptions"
section, and add "./typings/index.d.ts"
to the "files"
section. Finally, we need to add a new entry in "files"
for another file, "./src/model.ts"
, that we will create. Our tsconfig.json
should now look like this:
{ "compilerOptions": { "noImplicitAny": false, "noEmitOnError": true, "sourceMap": true, "target": "es5", "experimentalDecorators": true, "emitDecoratorMetadata": true, "outDir": "./Scripts/App" }, "files": [ "./src/app.ts", "./src/model.ts", "./src/main.ts", "./typings/index.d.ts" ] }
Please login to continue.