Add a TypeScript configuration file

Add a TypeScript configuration file

You’ll want to bring your TypeScript files together - both the code you’ll be writing as well as any necessary declaration files.

To do this, you’ll need to create a tsconfig.json which contains a list of your input files as well as all your compilation settings. Simply create a new file in your project root named tsconfig.json and fill it with the following contents:

{
  "compilerOptions": {
    "outDir": "./built/",
    "sourceMap": true,
    "noImplicitAny": true,
    "module": "amd",
    "target": "es5"
  },
  "files": [
    "./typings/index.d.ts",
    "./src/require-config.ts",
    "./src/hello.ts"
  ]
}

We’re including typings/index.d.ts, which Typings created for us. That file automatically includes all of your installed dependencies.

You can learn more about tsconfig.json files here.

doc_TypeScript
2016-10-04 19:24:58
Comments
Leave a Comment

Please login to continue.