You are here: Home / Topics / Project Structure - TypeScript

Project Structure - TypeScript

Filed under: TypeScript on 2024-03-18 12:45:47

Create two folders with the name ‘src’ and ‘public’. ‘src’ will be responsible to keep ts files & ‘public’ will be responsible to keep js & html files.
Execute the following commands:
tsc --init
This command will be responsible to create a tsconfig.json file. Open the tsconfig.json file & make some changes:
"target": "ES2015",
"outDir": "./public",
"rootDir": "./src",
"strict": true,
"include":["src"]
Now use either 'tsc' or 'tsc -w'

About Author:
J
Java Developer     View Profile
Hi, I am using MCQ Buddy. I love to share content on this website.