Using Three.js with TypeScript
The first thing we need to do is create a new Vite project. You can do these steps yourself, or you can look in the
three-ts folder and just run
yarn install there to skip this setup. To get an empty TypeScript project with Vite, all we have to do is run the following code in the console:
$ yarn create vite three-ts --template vanilla-ts yarn create v1.22.17 warning package.json: No license field [1/4] Resolving packages... [2/4] Fetching packages... [3/4] Linking...