К основному содержанию
скилл CX Codex

vite · itechmeat — скилл для Claude Code: что делает и как установить

Скилл помогает агенту настраивать и использовать Vite: от dev-сервера и сборки до плагинов, HMR и переменных окружения.

MIT 111 установок ★ 23 обновлён 2026-10-24

Установить в Claude Code · Через Skills CLI (Vercel) Все способы и платформы ↓
npx skills add itechmeat/llm-code --skill vite -a claude-code
Открыть на GitHub

Что делает vite

Скилл разбирает настройку Vite-проектов, запуск dev-сервера, сборку и работу с vite.config.*. Он подсказывает, как подключать плагины, использовать HMR и JavaScript API, загружать значения через loadEnv, настраивать режимы и переменные окружения.

Внутри есть правила для минимальной конфигурации, рецепты для npm create vite@latest, алиасов, multi-page приложений и оптимизации зависимостей через optimizeDeps.include/exclude. Также рассматриваются Environment API и переход от rollupOptions к rolldownOptions. Для проектов без index.html нужно отдельно задать верхнеуровневый input, иначе путь входного файла придётся повторять в настройках.

Скилл доступен для Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI и OpenCode. Для установки в Claude Code нужен доступ к npx и репозиторию itechmeat/llm-code.

Какие задачи решает

  • настроить vite.config.* под проект
  • запустить dev-сервер и сборку Vite
  • подключить плагин с нужными хуками
  • разобраться с HMR и JavaScript API
  • задать режимы и переменные окружения

Примеры запросов агенту

  • Настрой Vite-проект и создай конфигурацию в vite.config.*.
  • Добавь плагин Vite с хуками hotUpdate и apply, затем объясни настройки.
  • Собери приложение без index.html через верхнеуровневый input и проверь optimizeDeps.entries.

Как установить vite

1Через Skills CLI (Vercel)

npx skills add itechmeat/llm-code --skill vite -a claude-code

2Вручную: положить файлы

~/.claude/skills/vite/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/vite/

По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов

Вопросы о vite

Как установить vite в Claude Code?

Выполните npx skills add itechmeat/llm-code --skill vite -a claude-code, затем проверьте файл ~/.claude/skills/vite/SKILL.md.

Что делает скилл vite?

Он помогает агенту работать с Vite: настраивать dev-сервер и сборку, конфигурацию, плагины, HMR, Environment API и переменные окружения.

С какими платформами совместим vite?

Скилл предназначен для Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI и OpenCode.

Исходный текст

SKILL.md · MIT
---
name: vite
description: "Vite next-gen frontend tooling: dev server, HMR, build, config, plugins, Environment API, Rolldown. Use when setting up or running a Vite project, configuring vite.config.*, authoring plugins, working with HMR or JS API, or managing environment variables and modes. Keywords: vite.config, bundler, Vite, HMR, Rolldown."
metadata:
  version: "8.3.5"
  release_date: "2026-10-21"
---

# Vite

## Quick navigation

- Getting started: references/getting-started.md
- Philosophy and rationale: references/philosophy.md, references/why-vite.md
- Features: references/features.md
- CLI: references/cli.md
- Plugins (usage): references/using-plugins.md
- Plugin API: references/api-plugin.md
- HMR API: references/api-hmr.md
- JavaScript API: references/api-javascript.md
- Config reference: references/config.md
- Dependency optimization: references/dep-pre-bundling.md
- Assets: references/assets.md
- Build: references/build.md
- Static deploy: references/static-deploy.md
- Env & modes: references/env-and-mode.md
- SSR: references/ssr.md
- Backend integration: references/backend-integration.md
- Troubleshooting: references/troubleshooting.md
- Performance: references/performance.md
- Rolldown: references/rolldown.md
- Migration: references/migration.md
- Breaking changes: references/breaking-changes.md
- Environment API: references/api-environment.md
- Environment instances: references/api-environment-instances.md
- Env plugins: references/api-environment-plugins.md
- Env frameworks: references/api-environment-frameworks.md
- Env runtimes: references/api-environment-runtimes.md

## Core rules

- Prefer minimal configuration; extend only as needed.
- Keep `index.html` as a first-class entry point when using Vite defaults.
- Treat dev server settings and build settings separately.
- Document mode-dependent behavior for env variables and `define`.
- Use `future` config to opt-in to deprecation warnings before migration.

## Recipes

- Scaffold a project with `npm create vite@latest`.
- Configure aliases, server options, and build outputs in `vite.config.*`.
- Load `.env` values into config with `loadEnv` when config needs them.
- Add plugins with `plugins: []` and define `apply` or `enforce` when needed.
- Use HMR APIs for fine-grained updates when plugin or framework needs it.
- Use `optimizeDeps.include/exclude` when deps aren't discovered on startup.
- Use `build.rollupOptions.input` for multi-page apps.
- Use the top-level `input` option to declare the entry once for apps without `index.html`; it feeds `build.rolldownOptions.input`, `build.lib.entry`, `build.ssr`, and `optimizeDeps.entries` by default.
- Enable deprecation warnings: `future: { removeSsrLoadModule: 'warn' }`.
- Use `hotUpdate` hook instead of `handleHotUpdate` for environment-aware HMR.
- Use `this.environment` instead of `options.ssr` in plugin hooks.

## Release Highlights (8.0.0)

- Default browser target is raised again under `baseline-widely-available`.
- CommonJS default-import interop becomes more consistent and may expose packages that relied on older ambiguous behavior.
- Vite stops resolving `browser` vs `module` via format sniffing and follows configured `resolve.mainFields` more strictly.
- JS API `build()` now throws `BundleError` with nested `.errors` when multiple Rolldown-level errors are present.
- Rolldown transition becomes more explicit: `build.rollupOptions` / `worker.rollupOptions` are deprecated in favor of `*.rolldownOptions`.

## Release Highlights (8.1.0 -> 8.1.5)

- **WASM ESM integration**: direct `.wasm` imports work as ES modules natively.
- **Zero-config build caching**: integration with Vite Task enables build caching without manual setup.
- **`server.hmr` renamed to `server.ws`**: WebSocket options move under `server.ws`; update configs that set HMR transport options.
- **New options**: `html.additionalAssetSources` for custom asset sources during HTML transform, `import.meta.glob` `caseSensitive`, multiple hosts via `__VITE_ADDITIONAL_SERVER_ALLOWED_HOSTS`, and an extended default `server.fs.deny` list.
- **8.1.1 -> 8.1.5**: stability only (stack-trace handling, dependency bumps, module-resolution edge cases).

## Release Highlights (8.2.0)

- **New top-level `input` option**: `input: string | string[] | { [entryAlias: string]: string }` resolves relative to the project root and becomes the default value for `build.rolldownOptions.input`, `build.lib.entry`, `build.ssr` (when set to `true`), and `optimizeDeps.entries` whenever those are left unset; useful for apps that skip `index.html` and would otherwise repeat the same entry path in several options. The resolved `input` paths are also added to `server.fs.allow`, matching how imported modules are already allowed.
- **Bundled dev mode (`experimental.bundledDev`)**: a boundary-less edit now triggers exactly one reload; the client tells the server to rebuild first and only then issues `full-reload`, so the "bundling in progress" fallback page no longer flashes between an edit and the reload. Worker files (`new Worker(new URL(...))`, `?worker` imports) are now correctly re-emitted through HMR instead of going stale after an edit.
- **Native loader / native-config compatibility**: warnings about features unsupported by `configLoader: 'native'` now include a column alongside the line number, and virtual modules are excluded from the native-config compatibility check so plugin-generated virtual files no longer trigger false positives.
- **Type-safe PostCSS config**: Vite exports `PostcssUserConfig` (re-exported from `postcss-load-config`'s `Config` type) so `postcss.config.js`/`.ts` can be typed directly.
- **Network URL labeling**: dev server network URLs now resolve and print the OS network-interface name (e.g. `eth0`, `wlan0`) even when `server.host` is an explicit address, not only when Vite auto-detects every interface.
- **Rolldown and optimizer updates**: Rolldown bumps to `~1.2.0`, bringing client-side HMR handling into `experimental.bundledDev`; the dependency optimizer's lockfile-hash cache now also recognizes `aube-lock.yaml` (Aube) and `nub.lock` (nub), so those package managers correctly invalidate `node_modules/.vite` on dependency changes.

## Patch Notes (8.3.0 -> 8.3.5)

- The whole `8.3.x` line is fixes only — no new configuration options or APIs.
- **Bundled dev mode:** serves `/@vite/client` and stubs `@vite/env`, imports CSS HMR helpers from `/@vite/client`, applies `server.origin` to asset URLs, exposes user `import.meta.env.*` defines inside the `import.meta.env` object, maps forwarded error stacks through the bundle source maps, and stops HMR propagation at modules that are no longer imported.
- **Build:** chunk import maps handle missing imports and include preload dependencies in the hashing, preloads are corrected for a non-root `base` when `chunkImportMap` is enabled, the preload helper waits for in-flight stylesheets instead of scanning links quadratically, and a missing chunk import map no longer fails the build.
- **Optimizer:** falls back to `yarn.lock` for the lockfile hash, scans `oxc.jsxInject` imports, scans deep imports with custom extensions, and no longer skips imports whose binding starts with `type`.
- **CSS:** a literal `%` inside `url()` no longer fails the build, and preprocessors resolve from their own file path under lightningcss.
- **Server:** `transformIndexHtml` no longer receives the query string in the filename, static aliases match on path boundaries, and file-watcher errors no longer crash the dev server.

## Patch Notes (8.0.14 -> 8.0.16)

- Rolldown moves to `1.0.3` (was `1.0.2` in `8.0.14`); if you maintain plugin or build guidance, validate it against the current Rolldown behavior instead of assuming early `8.0.x` patch semantics.
- Dev server now sends HTTP `408` on request timeout instead of hanging the connection (`8.0.15`).
- `launch-editor-middleware` rejects UNC paths and Windows alternate paths, closing a local path-traversal vector (`8.0.16`); relevant if you expose the dev server beyond localhost.
- `8.0.15` fixes: `/@fs/` HTML-proxy cache-key mismatch, relative-glob-in-virtual-module errors when no files match, closing the Rolldown bundle when `write()` rejects, and `onWarn` for `viteResolvePlugin` in JS plugin containers.
- `transformIndexHtml` handles trailing-slash paths more reliably, which matters for plugins and static deploy setups that rewrite or inject HTML on directory-style URLs.
- Dependency scanning now passes Oxc JSX options through the optimizer path, so JSX-heavy linked dependencies should behave closer to the main transform pipeline.

## Prohibitions

- Do not copy large verbatim chunks from vendor docs.
- Do not assume framework-specific behavior without verifying.

## Links

- [Documentation](https://vite.dev/)
- [Releases](https://github.com/vitejs/vite/releases)
- [GitHub](https://github.com/vitejs/vite)
- [npm](https://www.npmjs.com/package/vite)

© itechmeat · MIT · itechmeat/llm-code

Похожие скиллы

Все скиллы по теме «Фронтенд и UI» →

Сначала — vite от других авторов.

vite Anthony Fu Разбирает конфигурацию Vite, плагины, SSR и сборку библиотек. Помогает настроить vite.config.ts и миграцию на Vite 8. CX Codex +1 42 400установок vite Mindrally Даёт агенту шаблоны конфигурации Vite: HMR, алиасы путей, сборку бандлов, интеграцию React, Vue и Vitest. CX Codex +1 875установок vite pproenca Набор из 42 правил оптимизации сборки и dev-сервера Vite. Помогает настроить конфигурацию, ускорить HMR и уменьшить размер бандла. CX Codex +1 376установок vite oakoss Описывает конфиг Vite, плагины, dev-сервер, сборку, SSR и переменные окружения. Задачи: правка vite.config.ts и сборка библиотек. CX Codex +1 138установок vite-patterns affaan-m Скилл vite-patterns подсказывает, как настраивать Vite, плагины, HMR, переменные окружения и сборку. Нужен при работе с vite.config.ts и Vite-проектами. CX Codex +1 6 500установок vite-advanced OrchestKit Скилл vite-advanced для Claude Code и Codex настраивает сборку Vite 8 на Rolldown, разделение чанков и Environment API. Включается при правке vite.config.* или файлов в каталогах **/vite/**. CX Codex +1 265установок vite-expert carlrannaberg Субагент vite-expert оптимизирует сборку Vite, настраивает HMR, SSR и чанкинг бандла. Пригодится при медленном dev-сервере или проблемах с ESM-модулями. CX Codex ★ 763звёзд репо vite-react-best-practices ant-gravity Скилл vite-react-best-practices задаёт агенту правила архитектуры, кэширования и деплоя для SPA на React 19 и Vite 8. Включается при сборке проекта, настройке роутинга или рефакторинге компонентов. CX Codex +1 670установок crxjs samber Настраивает HMR для popup, content scripts и side panel в Chrome-расширениях на CRXJS. Работает с проектами на Vite. CX Codex +1 5 100установок react-vite-best-practices agent-skills Скилл react-vite-best-practices для Claude Code с 23 правилами оптимизации React-приложений на Vite: сборка, code splitting, HMR, ассеты, окружение и анализ бандла. Проверяет компоненты при написании и ревью. CX Codex +1 3 000установок

Из того же набора16

Весь набор →
changelog Скилл задаёт структуру CHANGELOG.md по Keep a Changelog 1.1.0: разделы Added/Changed/Fixed, заголовки версий, даты ISO 8601 и ссылки на сравнения. CX Codex +1 192установок makefile Помогает агенту создавать и поддерживать Makefile: правила, переменные, рецепты, проверки и сборку. Автоматизирует команды проекта. CX Codex +1 181установок commits Помогает агенту оформлять Git-коммиты по Conventional Commits с учётом breaking changes. Формат используют для changelog и SemVer. CX Codex +1 178установок skill-master Скилл skill-master для Claude и других агентов: помогает писать, проверять и сравнивать Agent Skills по спецификации agentskills.io — от структуры папок до замеров срабатывания. CX Codex +1 161установок openapi Скилл подсказывает ИИ-агенту структуру документов OpenAPI 3.x: обязательные поля, операции, схемы, параметры и безопасность. CX Codex +1 125установок project-creator Скилл project-creator разворачивает структуру технической документации в папке .project/ и ведёт интервью, по шагам создавая спецификации, архитектуру и пользовательские истории. CX Codex +1 113установок fastapi Помогает создавать Python API на FastAPI. Он включается при работе с REST-маршрутами, Pydantic-моделями, зависимостями и OAuth2/JWT. CX Codex +1 100установок open-meteo Помогает запрашивать прогноз погоды, качество воздуха и координаты мест через Open-Meteo. Включается при работе с почасовыми, дневными или текущими показателями. CX Codex +1 100установок

Спонсоры проекта

Компании, которые помогают держать аналитику открытой