{
  "schemaVersion": "1.0",
  "item": {
    "slug": "vite",
    "name": "Vite",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/ivangdavila/vite",
    "canonicalUrl": "https://clawhub.ai/ivangdavila/vite",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/vite",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=vite",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "slug": "vite",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-10T17:42:34.525Z",
      "expiresAt": "2026-05-17T17:42:34.525Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=vite",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=vite",
        "contentDisposition": "attachment; filename=\"vite-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "vite"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/vite"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/vite",
    "agentPageUrl": "https://openagent3.xyz/skills/vite/agent",
    "manifestUrl": "https://openagent3.xyz/skills/vite/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/vite/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Environment Variables",
        "body": "Only VITE_ prefixed vars are exposed to client code — DB_PASSWORD stays server-side, VITE_API_URL is bundled\nAccess via import.meta.env.VITE_* not process.env — process.env is Node-only and undefined in browser\n.env.local overrides .env and is gitignored by default — use for local secrets\nimport.meta.env.MODE is development or production — use for conditional logic, not NODE_ENV"
      },
      {
        "title": "CommonJS Compatibility",
        "body": "Pure ESM by default — CommonJS packages need optimizeDeps.include for pre-bundling\nrequire() doesn't work in Vite — use import or createRequire from module for dynamic requires\nSome packages ship broken ESM — add to ssr.noExternal or optimizeDeps.exclude and let Vite transform them\nNamed exports from CommonJS may fail — use default import and destructure: import pkg from 'pkg'; const { method } = pkg"
      },
      {
        "title": "Dependency Pre-bundling",
        "body": "Vite pre-bundles dependencies on first run — delete node_modules/.vite to force rebuild after package changes\nLarge dependencies slow down dev server start — add rarely-changing ones to optimizeDeps.include for persistent cache\nLinked local packages (npm link) aren't pre-bundled — add to optimizeDeps.include explicitly\noptimizeDeps.force: true rebuilds every time — only for debugging, kills dev performance"
      },
      {
        "title": "Path Aliases",
        "body": "Configure in both vite.config.ts AND tsconfig.json — Vite uses its own, TypeScript uses tsconfig\nUse path.resolve(__dirname, './src') not relative paths — relative breaks depending on working directory\n@/ alias is not built-in — must configure manually unlike some frameworks\n\n// vite.config.ts\nresolve: {\n  alias: { '@': path.resolve(__dirname, './src') }\n}"
      },
      {
        "title": "Dev Server Proxy",
        "body": "Proxy only works in dev — production needs actual CORS config or reverse proxy\nchangeOrigin: true rewrites Host header — required for most APIs that check origin\nWebSocket proxy needs explicit ws: true — HTTP proxy doesn't forward WS by default\nTrailing slashes matter: /api proxies /api/users, /api/ only proxies /api//users\n\nserver: {\n  proxy: {\n    '/api': {\n      target: 'http://localhost:3000',\n      changeOrigin: true,\n      rewrite: path => path.replace(/^\\/api/, '')\n    }\n  }\n}"
      },
      {
        "title": "Static Assets",
        "body": "public/ files served at root, not processed — use for favicons, robots.txt, files that need exact paths\nsrc/assets/ files are processed, hashed, can be imported — use for images, fonts referenced in code\nImport assets to get resolved URL: import logo from './logo.png' — hardcoded paths break after build\nnew URL('./img.png', import.meta.url) for dynamic paths — template literals with variables don't work"
      },
      {
        "title": "Build Optimization",
        "body": "build.rollupOptions.output.manualChunks for code splitting — without it, one giant bundle\nAnalyze bundle with rollup-plugin-visualizer — find unexpected large dependencies\nbuild.target defaults to modern browsers — set 'es2015' for legacy support, but increases bundle size\nbuild.cssCodeSplit: true (default) — each async chunk gets its own CSS file"
      },
      {
        "title": "Library Mode",
        "body": "build.lib for npm packages — different config from app mode\nSet external for peer dependencies — don't bundle React/Vue into your library\nGenerate types separately with tsc — Vite doesn't emit .d.ts files\nBoth ESM and CJS outputs: formats: ['es', 'cjs'] — some consumers still need require()"
      },
      {
        "title": "HMR Issues",
        "body": "Circular imports break HMR — refactor to break the cycle or full reload triggers\nState lost on HMR means component isn't accepting updates — check for import.meta.hot.accept()\nCSS changes trigger full reload if imported in JS that doesn't accept HMR — import CSS in components that do\nserver.hmr.overlay: false hides error overlay — useful for custom error handling but hides issues"
      },
      {
        "title": "SSR Configuration",
        "body": "ssr.external for Node-only packages — prevents bundling node_modules in SSR build\nssr.noExternal forces bundling — needed for packages with browser-specific imports\nCSS imports fail in SSR by default — use ?inline suffix or configure css.postcss for SSR"
      }
    ],
    "body": "Vite Patterns\nEnvironment Variables\nOnly VITE_ prefixed vars are exposed to client code — DB_PASSWORD stays server-side, VITE_API_URL is bundled\nAccess via import.meta.env.VITE_* not process.env — process.env is Node-only and undefined in browser\n.env.local overrides .env and is gitignored by default — use for local secrets\nimport.meta.env.MODE is development or production — use for conditional logic, not NODE_ENV\nCommonJS Compatibility\nPure ESM by default — CommonJS packages need optimizeDeps.include for pre-bundling\nrequire() doesn't work in Vite — use import or createRequire from module for dynamic requires\nSome packages ship broken ESM — add to ssr.noExternal or optimizeDeps.exclude and let Vite transform them\nNamed exports from CommonJS may fail — use default import and destructure: import pkg from 'pkg'; const { method } = pkg\nDependency Pre-bundling\nVite pre-bundles dependencies on first run — delete node_modules/.vite to force rebuild after package changes\nLarge dependencies slow down dev server start — add rarely-changing ones to optimizeDeps.include for persistent cache\nLinked local packages (npm link) aren't pre-bundled — add to optimizeDeps.include explicitly\noptimizeDeps.force: true rebuilds every time — only for debugging, kills dev performance\nPath Aliases\nConfigure in both vite.config.ts AND tsconfig.json — Vite uses its own, TypeScript uses tsconfig\nUse path.resolve(__dirname, './src') not relative paths — relative breaks depending on working directory\n@/ alias is not built-in — must configure manually unlike some frameworks\n// vite.config.ts\nresolve: {\n  alias: { '@': path.resolve(__dirname, './src') }\n}\n\nDev Server Proxy\nProxy only works in dev — production needs actual CORS config or reverse proxy\nchangeOrigin: true rewrites Host header — required for most APIs that check origin\nWebSocket proxy needs explicit ws: true — HTTP proxy doesn't forward WS by default\nTrailing slashes matter: /api proxies /api/users, /api/ only proxies /api//users\nserver: {\n  proxy: {\n    '/api': {\n      target: 'http://localhost:3000',\n      changeOrigin: true,\n      rewrite: path => path.replace(/^\\/api/, '')\n    }\n  }\n}\n\nStatic Assets\npublic/ files served at root, not processed — use for favicons, robots.txt, files that need exact paths\nsrc/assets/ files are processed, hashed, can be imported — use for images, fonts referenced in code\nImport assets to get resolved URL: import logo from './logo.png' — hardcoded paths break after build\nnew URL('./img.png', import.meta.url) for dynamic paths — template literals with variables don't work\nBuild Optimization\nbuild.rollupOptions.output.manualChunks for code splitting — without it, one giant bundle\nAnalyze bundle with rollup-plugin-visualizer — find unexpected large dependencies\nbuild.target defaults to modern browsers — set 'es2015' for legacy support, but increases bundle size\nbuild.cssCodeSplit: true (default) — each async chunk gets its own CSS file\nLibrary Mode\nbuild.lib for npm packages — different config from app mode\nSet external for peer dependencies — don't bundle React/Vue into your library\nGenerate types separately with tsc — Vite doesn't emit .d.ts files\nBoth ESM and CJS outputs: formats: ['es', 'cjs'] — some consumers still need require()\nHMR Issues\nCircular imports break HMR — refactor to break the cycle or full reload triggers\nState lost on HMR means component isn't accepting updates — check for import.meta.hot.accept()\nCSS changes trigger full reload if imported in JS that doesn't accept HMR — import CSS in components that do\nserver.hmr.overlay: false hides error overlay — useful for custom error handling but hides issues\nSSR Configuration\nssr.external for Node-only packages — prevents bundling node_modules in SSR build\nssr.noExternal forces bundling — needed for packages with browser-specific imports\nCSS imports fail in SSR by default — use ?inline suffix or configure css.postcss for SSR"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/ivangdavila/vite",
    "publisherUrl": "https://clawhub.ai/ivangdavila/vite",
    "owner": "ivangdavila",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/vite",
    "downloadUrl": "https://openagent3.xyz/downloads/vite",
    "agentUrl": "https://openagent3.xyz/skills/vite/agent",
    "manifestUrl": "https://openagent3.xyz/skills/vite/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/vite/agent.md"
  }
}