https://github.com/neuodev/typescript-project-setup
https://github.com/neuodev/typescript-project-setup
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/neuodev/typescript-project-setup
- Owner: neuodev
- Created: 2022-06-11T17:46:44.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2022-06-11T17:56:17.000Z (about 4 years ago)
- Last Synced: 2025-03-02T07:02:47.053Z (over 1 year ago)
- Language: TypeScript
- Size: 13.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Typescript Setup
This repo is part of [YouTube Tutorial](https://www.youtube.com/watch?v=-Uo5ahVrZ_E)
[](https://www.youtube.com/watch?v=-Uo5ahVrZ_E)
1. Initalize NPM
```bash
npm init
```
2. Install TS
```bash
npm i typescript --save-dev
```
3. Initalize the porject
```bash
npx tsc --init
```
4. Compile TS to JS
```bash
npx tsc
```
- you can use `npx tsc -W` to watch for code changes
- Create `src` and `dist` folders
5. Download `ts-node-dev`
```bash
npm i ts-node-dev --save-dev
```
6. Add new Script to your `package.json`
```bash
ts-node-dev --respawn src/index.ts
```