This is a straightforward configuration of P5.js, TypeScript, and Vite. Will mostly be used by me to make a few hobby projects and to teach younger family members how to code without the added overhead of setup.
You can follow the below steps to get started or you can just select "Use this template" on the repository's page.
git clone https://github.com/rcoleworld/vite-p5-starter.git
npm install
To start vite dev server:
npm run dev
For production builds and deploying please refer to the vite documentation.
Inside of /src/main.ts, add your code to the provided draw() and setup() methods. For more information about how these methods work or for more documentation on P5.js refer to the docs.