01
It starts by itself
PR opened or updated. Runs in GitHub Actions or Claude Code routine.
- ↻ PR opened or updated
pull_request.opened, pull_request.synchronize
Your Vite bundle stays lean.
Install the React Vite Best Practices skill and make it a habit: follow https://gethabit.dev/skills/asyrafhussin/react-vite-best-practices.md
3K installs92 starsMIT licenceSource on GitHub ↗

React Vite Best Practices
by asyrafhussin · 3K installs
The skill
The react vite best practices skill gives React developers 23 rules for Vite builds, code splitting, HMR, assets, environment variables and bundle analysis, ranked by impact.
Only when you ask.
The habit
Your Vite bundle stays lean.
↻ Runs by itselfPR opened or updated
When does it start? How does it check its work? What does it remember?
Stops after one build and one review per pull request.
The agent loads chunk sizes from the last build.
The production build must pass.
No chunk may cross chunkSizeWarningLimit, and growth since last run gets flagged.
rollup-plugin-visualizer shows which dependencies grew.
Heavy routes load through React.lazy inside Suspense boundaries.
Only VITE_ variables reach client code, and none hold secrets.
Chunk sizes and the critic's notes go into the run log.
It writes only in its own folder and asks you before anything goes out.
Read both lists. If the left one sounds like you, the React Vite Best Practices skill helps.
The skill's 23 rules across build, code splitting, development, assets, env config and bundle analysis.
No. The loop reports and suggests changes. You decide what goes into the config.
Copy the prompt at the top into your agent. It installs the skill from asyrafhussin/agent-skills and sets up the habit. Or run npx skills add asyrafhussin/agent-skills --skill react-vite-best-practices.
Yes. It is published under MIT. Habit is free too.
Install the React Vite Best Practices skill and make it a habit: follow https://gethabit.dev/skills/asyrafhussin/react-vite-best-practices.md
All asyrafhussin skills →More code skills →
Works in
Made by asyrafhussin, published under MIT. Habit links to the original and never changes it. Is this your skill?