Note: We're using yarn instead of npm.
Hit the Run button to start the server in dev mode. Or run this command in a shell.
yarn dev
Put your typescript files inside of /src and they will automatically get compiled into javascript inside of /dist.
Under the hood what this command is doing is
- Compiling typescript into js.
- Using nodemon to create a server with live updates.
To start production (and stop using nodemon) you can run:
yarn start
You can also configure the Run button to run this command.
Note that this will disable the live updates.