What is the intended behaviour for tsc command in packages/app-desktop?

Running the yarn watch command in packages/app-desktop runs the following command:

tsc --watch --preserveWatchOutput --project tsconfig.json

This creates .js and .js.map files in the command root directory, making navigation and development difficult. However, I noticed the following in the tsconfig.json in this directory:

"exclude": [
		"**/node_modules",
		"**/dist",

With that reference, isn't the intended behaviour supposed to create the js files in the /dist directory, or in other words, should the tsconfig not have any outDir configured ? I just wanted to know what the intended behaviour is.

Any help is appreciated.

1 Like

This is intended behavior (but it can make development more difficult).

The dist folder is used when building a release version of the desktop app (e.g. with cd packages/app-desktop/ && yarn dist --publish=never).

The default vscode workspace may hide these auto-generated .js and .js.map files.

1 Like