Communityコーディング&開発github.com

onmax/vite

Viteビルドツールの設定、プラグインAPI、SSR、Vite 8 Rolldown移行。Viteプロジェクト、vite.config.ts、Viteプラグイン、またはViteを使用したライブラリ/SSRアプリの構築時に使用します。

vite とは?

このスキルは、Viteビルドツールに関する設定、プラグインAPI、SSR(サーバーサイドレンダリング)、およびVite 8へのRolldownマイグレーションをサポートします。Viteプロジェクトでvite.config.tsの設定、カスタムプラグインの開発、ライブラリやSSRアプリケーションの構築を行う開発者に最適です。CLIコマンド、Node.js API、環境変数などの実践的な設定例を提供し、効率的な開発を支援します。対応プラットフォームはClaude Code、Cursor、Codexなどの主要なAIエージェントツールです。

対応~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/onmax/nuxt-skills/tree/main/skills/vite

Installed? Explore more コーディング&開発 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

vite は何をしますか?

Viteビルドツールの設定、プラグインAPI、SSR、Vite 8 Rolldown移行に関するスキルです。Viteプロジェクト、vite.config.ts、Viteプラグイン、またはViteを使用したライブラリ/SSRアプリの構築時に使用します。

機能

  • Viteの設定(vite.config.ts)の最適化
  • カスタムプラグインの開発とAPIの活用
  • SSR(サーバーサイドレンダリング)の設定と実装
  • Vite 8へのRolldown移行ガイド
  • 実践的な設定例とトラブルシューティング

使用方法

設定例

// vite.config.ts
export default defineConfig({
  plugins: [vue()],
  build: {
    target: 'es2020',
    rollupOptions: {
      // Rolldown 移行時の設定
    }
  },
  ssr: {
    target: 'node',
    noExternal: ['some-package']
  }
});

プラグイン開発

import type { Plugin } from 'vite';

function myPlugin(): Plugin {
  return {
    name: 'vite-plugin-example',
    enforce: 'pre',
    transform(code, id) {
      if (id.endsWith('.vue')) {
        // カスタム変換
      }
    }
  };
}

対応プラットフォーム

  • Claude Code
  • Cursor
  • Codex
  • その他のAIエージェント

注意事項

  • Vite 8ではRolldownがデフォルトのバンドラになります。移行ガイドを参照してください。
  • SSR設定ではNode.jsバージョンに注意してください。

Individual skills in this repo

This repo contains 15 individual skills — each has its own dedicated page.

onmax/document-writer

Use when writing blog posts or documentation markdown files - provides writing style guide (active voice, present tense), content structure patterns, and MDC component usage. Overrides brevity rules for proper grammar. Use nuxt-content for MDC syntax, nuxt-ui for component props.

onmax/motion

Use when adding animations with Motion Vue (motion-v) - provides motion component API, gesture animations, scroll-linked effects, layout transitions, and composables for Vue 3/Nuxt

onmax/nuxt

Use when working on Nuxt 4+ projects - provides server routes, file-based routing, middleware patterns, Nuxt-specific composables, and configuration with latest docs. Covers h3 v1 helpers (validation, WebSocket, SSE) and nitropack v2 patterns. Updated for Nuxt 4.3+.

onmax/nuxt-better-auth

Use when implementing auth in Nuxt apps with @onmax/nuxt-better-auth - provides useUserSession composable, server auth helpers, route protection, and Better Auth plugins integration.

onmax/nuxt-content

Use when working with Nuxt Content v3, markdown content, or CMS features in Nuxt - provides collections (local/remote/API sources), queryCollection API, MDC rendering, database configuration, NuxtStudio integration, hooks, i18n patterns, and LLMs integration

onmax/nuxthub

Use when building NuxtHub v0.10.6 applications - provides database (Drizzle ORM with sqlite/postgresql/mysql), KV storage, blob storage, and cache APIs. Covers configuration, schema definition, migrations, multi-cloud deployment (Cloudflare, Vercel), and the new hub:db, hub:kv, hub:blob virtual module imports.

onmax/nuxt-modules

Use when creating Nuxt modules: (1) Published npm modules (@nuxtjs/, nuxt-), (2) Local project modules (modules/ directory), (3) Runtime extensions (components, composables, plugins), (4) Server extensions (API routes, middleware), (5) Releasing/publishing modules to npm, (6) Setting up CI/CD workflows for modules. Provides defineNuxtModule patterns, Kit utilities, hooks, E2E testing, and release automation.

onmax/nuxt-seo

Nuxt SEO meta-module with robots, sitemap, og-image, schema-org. Use when configuring SEO, generating sitemaps, creating OG images, or adding structured data.

onmax/nuxt-ui

Use when building styled UI with @nuxt/ui v4 components - create forms with validation, implement data tables with sorting, build modal dialogs and overlays, configure Tailwind Variants theming. Use vue skill for raw component patterns, reka-ui for headless primitives.

onmax/pnpm

Use when managing Node.js dependencies with pnpm - install packages, configure monorepo workspaces, set up pnpm catalogs, resolve dependency conflicts with overrides, patch third-party packages, and configure CI pipelines for pnpm projects

onmax/reka-ui

Use when building with Reka UI (headless Vue components) - provides component API, accessibility patterns, composition (asChild), controlled/uncontrolled state, virtualization, and styling integration. Formerly Radix Vue.

onmax/ts-library

Use when authoring TypeScript libraries or npm packages - covers project setup, package.json exports, build tooling (tsdown/unbuild), API design patterns, type inference tricks, testing, and publishing to npm. Use when bundling, configuring dual CJS/ESM output, or setting up release workflows.

onmax/vitest

Use when writing unit/integration tests for Vite projects - configure vitest.config.ts, write test suites with describe/it, create mock implementations with vi.fn and vi.mock, set up code coverage thresholds, and run tests in parallel

onmax/vue

Use when editing .vue files, creating Vue 3 components, writing composables, or testing Vue code - provides Composition API patterns, props/emits best practices, VueUse integration, and reactive destructuring guidance

onmax/vueuse

Use when working with VueUse composables - track mouse position with useMouse, manage localStorage with useStorage, detect network status with useNetwork, debounce values with refDebounced, and access browser APIs reactively. Check VueUse before writing custom composables - most patterns already implemented.

関連スキル