vite

Configure Vite build tooling, plugins, SSR, and Rolldown migration for frontend projects.

1|Updated Apr 3, 2026
One-click install
npx skills add https://github.com/TierOne-Studio/spa-velocity --skill vite-tierone-studio
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vite
Source: https://github.com/TierOne-Studio/spa-velocity/tree/main/.ruler/skills/vite
Command: npx skills add https://github.com/TierOne-Studio/spa-velocity --skill vite-tierone-studio

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Frontend developers working with Vite need accurate, up-to-date guidance on configuration, plugin authoring, SSR setup, and the breaking changes introduced by Vite 8's Rolldown bundler, without digging through scattered documentation. ## Core Features & Use Cases - Configuration Guidance: Covers vite.config.ts, defineConfig, conditional configs, loadEnv, aliases, proxies, and build targets. - Plugin Authoring: Explains Vite-specific hooks, virtual modules, plugin ordering, and client-server HMR communication. - Build & SSR: Documents library mode, multi-page apps, the JavaScript API, and SSR middleware patterns. - Vite 8 Migration: Maps rollupOptions to rolldownOptions and esbuild to oxc for the Rolldown-powered release. - Use Case: When upgrading a project to Vite 8, use this Skill to rewrite the config for Rolldown and Oxc, then verify plugin compatibility. ## Quick Start Ask the AI to review my vite.config.ts and migrate it to Vite 8 with Rolldown and Oxc settings.

Frequently Asked Questions about vite

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure path aliases in vite.config.ts?

Use the resolve.alias option in vite.config.ts to map shortcuts like '@' to '/src'. Define the config with defineConfig from 'vite' and place alias entries under the resolve key.

How to migrate from Vite 7 to Vite 8 Rolldown?

Rename rollupOptions to rolldownOptions and replace the esbuild option with oxc in your config. For large projects, test first with the rolldown-vite package before upgrading the vite dependency to version 8.

Does Vite support SSR for application development?

Vite's SSR support is low-level and intended for meta-framework authors rather than application developers. For app SSR, use frameworks built on Vite such as Nuxt, SvelteKit, SolidStart, or TanStack Start.

How do I create a virtual module in a Vite plugin?

Implement resolveId and load hooks in your plugin, using a 'virtual:' prefix for the user-facing id and a '\0' prefix for the resolved id. The load hook returns the module's source code as a string.

Why are my environment variables undefined in Vite client code?

Only variables prefixed with VITE_ are exposed to client-side code via import.meta.env. Variables without the prefix, like database passwords, remain server-side only and return undefined in the browser.

Are Rollup plugins compatible with Vite 8 Rolldown?

Most Vite plugins work unchanged because Rolldown supports Rollup's plugin API. If a plugin only works during build, wrap it with enforce 'post' and apply 'build' to restrict when it runs.