Why has WebStorm decided not to compile one of my TypeScript files?

I have 4 TypeScript files. 3 of them WebStorm is automatically compiling to JavaScript, one of them it's not. Maybe I accidentally answered "no" at some point when it prompted me. But how can I go back in and change this setting myself?
Please sign in to leave a comment.
>Maybe I accidentally answered "no" at some point when it prompted me.
There is no way to enable/disable compiling for individual files in WebStorm:)
Do you have tsconfig.json file(s) in your project? If yes, what do they look like?
Also, what are your TypeScript settings (Settings | Languages & Frameworks | TypeScript)? Please attach screenshot.
Note also that some compiler errors might prevent javascript from being emitted; also, no js is produced for declaration files, etc.
BTW, does this file compile when you run tsc in terminal?
tsconfig:
```
{

"compilerOptions": {
"lib": ["es6"],
"module": "commonjs",
"noImplicitReturns": true,
"outDir": "lib",
"sourceMap": true,
"target": "es5",
"allowJs": true
},
"compileOnSave": true,
"include": [
"src",
"test"
]
}
```
I noticed that the dropdown list "Compile scope" has an optino for "Project test files". This file is a test file. What exactly does this dropdown menu do?
and yes, it does compile with tsc, but it goes to a different folder. I guess that could be a solution. I have things set up right now so mocha would look for the files that the IDE was compiling automatically (except that it wasn't compiling this one file)
>and yes, it does compile with tsc, but it goes to a different folder
TypeScript service in WebStorm should work in the same way - put generated files to lib folder. Please delete the generated files located next to .ts and try modifying the ts files - are the js files emitted? If yes, where are they saved to?
Oh interesting. I deleted the js files and the js.map files that were living beside my ts files. I changed something in the ts file, and it's no longer generating new js files in the same folder. Why would it stop doing that? Is it because I added the tsconfig, does that override the behavior of WebStorm automatically compiling my typescript to js files right beside it?
> Is it because I added the tsconfig, does that override the behavior of WebStorm automatically compiling my typescript to js files right beside it?
yes, exactly: when there is a tsconfig.json current ts file is included in, WebStorm uses settings from it when compiling the file. If no tsconfig.json files are found, default settings are used (in particular, js files are generated next to original ts files)
awesome, thank you