Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

atom-typescript: set experimentalDecorators option

I have begun using the Atom editor with the atom-typescript package on an existing project, and I am encountering this warning.

Experimental support for decorators is a feature that is subject to change in a future release. Set the 'experimentalDecorators' option to remove this warning.

I cannot seem to figure out how to do this. I tried adding "experimentalDecorators": true to the compilerOptions in ~/.atom/packages/atom-typescript/lib/tsconfig.json but this did not help. What can I do to get rid of the warning?

like image 526
Barry McNamara Avatar asked Jun 23 '17 13:06

Barry McNamara


1 Answers

In order to configure a particular project's TypeScript compiler settings, you need to create a tsconfig.json in the root directory of that project, like so:

{
    "compilerOptions": {
        "experimentalDecorators": true
    }
}

tsc and your editor plugin will both pick this up automatically, and the warning should disappear.

like image 103
Joe Clay Avatar answered Sep 27 '22 23:09

Joe Clay