Opinionated Vite starter template.
- Vite 2 with React Typescript and absolute imports.
- Tailwind CSS v2.1 with the new JIT engine enabled, a basic reset for form styles and dark mode.
- Use ESLint, stylelint and Prettier on your IDE and before you commit with Husky and lint-staged.
- PWA with 17/17 Lighthouse score.
- Write e2e tests with Cypress.
- GitHub Actions for dependency updates, CodeQL Analysis, running Cypress tests and code coverage with Codecov.
- Deploy to Vercel with pre-configured SPA fallback.
Use this repository as a GitHub template or use degit to clone to your machine with an empty git history:
npx degit wtchnm/Vitamin#main my-app
Then, install the dependencies:
yarn install
- If you don't plan to use GitHub Actions, delete the
.github
directory. - Clean up the
cypress/integration/index.spec.ts
file. - Change the
favicon.png
,apple-touch-icon.png
,android-chrome-192x192.png
andandroid-chrome-512x512.png
. favicon.io is a cool tool for generating these assets. - Remove the
fruits.json
in the public folder. - In the
src
folder, remove theapi
andcomponents
folder and thetypes.ts
file. - If you don't plan to use
react-query
, remove the query client logic in themain.tsx
file. - Change the title, description and theme color in the
index.html
andvite.config.ts
. Inter font is included, so remove it if you want. - Modify or delete the
LICENSE
file. - Change the
name
field in package.json.
Just run yarn dev
.
Run yarn build
. The generated files will be on the dist
folder.
Run yarn test
. Tests are performed on production build, so be sure to build your app first.