There are many great Threejs examples on the official Threejs examples website at https://threejs.org/examples/
- I base the new project on the statsgui branch of my boilerplate because it already includes the Stats and DAT.gui panels.
- I make sure all resource that the script needs are available such as any resources referenced in the examples html, or images/models that will also need to be placed in your project dist folders.
- I then proceed to convert all var keywords to let or const and add Type Annotations to all of the variable declarations.
View the converted project on codesandbox.io