Skip to content

Upgrade build pipeline to Vite 8#1115

Draft
johnbillion with Copilot wants to merge 2 commits into
developfrom
copilot/update-vite-to-version-8
Draft

Upgrade build pipeline to Vite 8#1115
johnbillion with Copilot wants to merge 2 commits into
developfrom
copilot/update-vite-to-version-8

Conversation

Copilot AI commented May 11, 2026

Copy link
Copy Markdown

This updates the frontend build toolchain to Vite 8 and applies the required migration away from deprecated Rollup-specific config paths. It also removes Vite 7-only integration code and dependencies that are no longer compatible/needed.

  • Dependency upgrades and removals

    • Upgraded vite from ^7.3.1 to ^8.0.11.
    • Upgraded @preact/preset-vite to ^2.10.5 to match Vite 8 peer support.
    • Removed @kucrut/vite-for-wp (locked to Vite 7 peer range).
  • Vite 8 migration

    • Migrated build config from build.rollupOptions to build.rolldownOptions in:
      • vite.config.js
      • vite.extension.config.js
    • Kept output contract unchanged (query-monitor.js, stable asset names, existing out dirs).
  • Replacement of removed plugin behavior

    • Replaced v4wp() usage with explicit native Vite config (base, build.outDir, emptyOutDir, modulePreload, css.devSourcemap, dev server settings).
    • Added a small local Vite plugin to emit/remove assets/build/vite-dev-server.json during dev so existing PHP manifest detection continues to work.
build: {
  rolldownOptions: {
    input: {
      main: 'src/index.tsx',
      'query-monitor': 'assets/query-monitor.css',
      toolbar: 'assets/toolbar.css',
    },
    output: {
      entryFileNames: 'query-monitor.js',
      assetFileNames: '[name][extname]',
    },
  },
}

Copilot AI and others added 2 commits May 11, 2026 03:20
Agent-Logs-Url: https://github.com/johnbillion/query-monitor/sessions/7c509ec8-0e80-4459-a51b-ee7199fab7f9

Co-authored-by: johnbillion <208434+johnbillion@users.noreply.github.com>
Agent-Logs-Url: https://github.com/johnbillion/query-monitor/sessions/7c509ec8-0e80-4459-a51b-ee7199fab7f9

Co-authored-by: johnbillion <208434+johnbillion@users.noreply.github.com>
@johnbillion johnbillion changed the title Upgrade build pipeline to Vite 8 and migrate off @kucrut/vite-for-wp Upgrade build pipeline to Vite 8 May 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants