diff --git a/packages/vite/package.json b/packages/vite/package.json index 8193033b73be67..b9d79f4329bc82 100644 --- a/packages/vite/package.json +++ b/packages/vite/package.json @@ -87,7 +87,8 @@ "dependencies": { "esbuild": "^0.24.0", "postcss": "^8.4.47", - "rolldown": "https://pkg.pr.new/rolldown@1fa5d4b", + "react-refresh": "^0.14.2", + "rolldown": "0.13.2-snapshot-a292401-20241105072341", "rollup": "^4.22.5" }, "optionalDependencies": { diff --git a/packages/vite/src/node/config.ts b/packages/vite/src/node/config.ts index 94e0ad1e6e20e3..70e81835c41ffb 100644 --- a/packages/vite/src/node/config.ts +++ b/packages/vite/src/node/config.ts @@ -89,6 +89,7 @@ import { resolveSSROptions } from './ssr' import { PartialEnvironment } from './baseEnvironment' import { createIdResolver } from './idResolver' import { type OxcOptions, convertEsbuildConfigToOxcConfig } from './plugins/oxc' +import { rolldownDevPluginConfig } from './server/environments/rolldown' const debug = createDebugger('vite:config') const promisifiedRealpath = promisify(fs.realpath) @@ -508,6 +509,9 @@ export interface ExperimentalOptions { * @default true */ enableNativePlugin?: boolean + + rolldownDev?: boolean + rolldownDevReactRefresh?: boolean } export interface LegacyOptions { @@ -1009,6 +1013,9 @@ export async function resolveConfig( // run config hooks const userPlugins = [...prePlugins, ...normalPlugins, ...postPlugins] config = await runConfigHook(config, userPlugins, configEnv) + if (config.experimental?.rolldownDev) { + config = mergeConfig(config, rolldownDevPluginConfig(config)) + } // Ensure default client and ssr environments // If there are present, ensure order { client, ssr, ...custom } diff --git a/packages/vite/src/node/plugins/index.ts b/packages/vite/src/node/plugins/index.ts index b4e5e5f6b1fa55..9f5b234dafeb0b 100644 --- a/packages/vite/src/node/plugins/index.ts +++ b/packages/vite/src/node/plugins/index.ts @@ -171,6 +171,11 @@ export async function resolvePlugins( }) : importGlobPlugin(config), + // TODO: cyclic import? + !isBuild && + config.experimental.rolldownDev && + (await import('../server/environments/rolldown')).rolldownDevPlugin(), + ...postPlugins, ...buildPlugins.post, diff --git a/packages/vite/src/node/server/environments/rolldown.ts b/packages/vite/src/node/server/environments/rolldown.ts new file mode 100644 index 00000000000000..a3d4ed595f1456 --- /dev/null +++ b/packages/vite/src/node/server/environments/rolldown.ts @@ -0,0 +1,426 @@ +/* eslint-disable no-console */ +import assert from 'node:assert' +import fs from 'node:fs' +import { createRequire } from 'node:module' +import path from 'node:path' +import { pathToFileURL } from 'node:url' +import MagicString from 'magic-string' +import * as rolldown from 'rolldown' +import * as rolldownExperimental from 'rolldown/experimental' +import sirv from 'sirv' +import { createLogger } from '../../publicUtils' +import { DevEnvironment } from '../environment' +import type { + DevEnvironmentOptions, + HmrContext, + Plugin, + ResolvedConfig, + UserConfig, + ViteDevServer, +} from '../..' + +const require = createRequire(import.meta.url) + +interface ViterollOptions { + reactRefresh?: boolean +} + +const logger = createLogger('info', { + prefix: '[rolldown]', + allowClearScreen: false, +}) + +export function rolldownDevPluginConfig(config: UserConfig): UserConfig { + return { + appType: 'custom', + optimizeDeps: { + noDiscovery: true, + }, + define: { + // TODO: use vite:define plugin + 'process.env.NODE_ENV': "'development'", + }, + environments: { + client: { + dev: { + createEnvironment: RolldownEnvironment.createFactory({ + reactRefresh: config.experimental?.rolldownDevReactRefresh, + }), + }, + // NOTE + // this is not "build" option any more (or is there a way to handle entry lazily?) + build: { + rollupOptions: { + input: + config.build?.rollupOptions?.input ?? + config.environments?.client.build?.rollupOptions?.input ?? + './index.html', + }, + }, + }, + ssr: { + dev: { + createEnvironment: RolldownEnvironment.createFactory({ + reactRefresh: false, + }), + }, + }, + }, + } +} + +export function rolldownDevPlugin(): Plugin { + let server: ViteDevServer + let environments: Record<'client' | 'ssr', RolldownEnvironment> + + return { + name: 'vite:rolldown-dev', + configureServer(server_) { + server = server_ + environments = server.environments as any + + // rolldown server as middleware + server.middlewares.use( + sirv(environments.client.outDir, { dev: true, extensions: ['html'] }), + ) + + // full build on non self accepting entry + server.ws.on('rolldown:hmr-deadend', async (data) => { + logger.info(`hmr-deadend '${data.moduleId}'`, { timestamp: true }) + await environments.client.build() + server.ws.send({ type: 'full-reload' }) + }) + + // disable automatic html reload + // https://github.com/vitejs/vite/blob/01cf7e14ca63988c05627907e72b57002ffcb8d5/packages/vite/src/node/server/hmr.ts#L590-L595 + const oldSend = server.ws.send + server.ws.send = function (...args: any) { + const arg = args[0] + if ( + arg && + typeof arg === 'object' && + arg.type === 'full-reload' && + typeof arg.path === 'string' && + arg.path.endsWith('.html') + ) { + return + } + oldSend.apply(this, args) + } + }, + async handleHotUpdate(ctx) { + await environments.ssr.handleUpdate(ctx) + await environments.client.handleUpdate(ctx) + }, + transform(code, id) { + // remove unnecessary /@vite/env + if (id.endsWith('/vite/dist/client/client.mjs')) { + code = code.replace(`import '@vite/env'`, '/* @vite/env removed */') + return { code, map: null } + } + }, + } +} + +export class RolldownEnvironment extends DevEnvironment { + instance!: rolldown.RolldownBuild + result!: rolldown.RolldownOutput + outDir!: string + buildTimestamp = Date.now() + + static createFactory( + viterollOptions: ViterollOptions, + ): NonNullable { + return (name, config) => + new RolldownEnvironment(viterollOptions, name, config) + } + + constructor( + public viterollOptions: ViterollOptions, + name: ConstructorParameters[0], + config: ConstructorParameters[1], + ) { + super(name, config, { hot: false }) + this.outDir = path.join(this.config.root, this.config.build.outDir) + } + + override init: DevEnvironment['init'] = async () => { + await super.init() + await this.build() + } + + override close: DevEnvironment['init'] = async () => { + await super.close() + await this.instance?.close() + } + + async build(): Promise { + if (!this.config.build.rollupOptions.input) { + return + } + + await this.instance?.close() + + if (this.config.build.emptyOutDir !== false) { + fs.rmSync(this.outDir, { recursive: true, force: true }) + } + + // TODO: how to pass user plugins? + // simply reusing them would have a same issue as Vite 6 `sharedConfigBuild`. + // this.config.plugins + + console.time(`[rolldown:${this.name}:build]`) + const inputOptions: rolldown.InputOptions = { + // TODO: no dev ssr for now + dev: this.name === 'client', + input: this.config.build.rollupOptions.input, + cwd: this.config.root, + platform: this.name === 'client' ? 'browser' : 'node', + resolve: { + conditionNames: this.config.resolve.conditions, + mainFields: this.config.resolve.mainFields, + symlinks: !this.config.resolve.preserveSymlinks, + }, + define: this.config.define, + plugins: [ + viterollEntryPlugin(this.config, this.viterollOptions), + // TODO: how to use jsx-dev-runtime? + rolldownExperimental.transformPlugin({ + reactRefresh: + this.name === 'client' && this.viterollOptions?.reactRefresh, + }), + this.name === 'client' && this.viterollOptions?.reactRefresh + ? reactRefreshPlugin() + : [], + rolldownExperimental.aliasPlugin({ + entries: this.config.resolve.alias, + }), + ], + } + this.instance = await rolldown.rolldown(inputOptions) + + // `generate` should work but we use `write` so it's easier to see output and debug + const outputOptions: rolldown.OutputOptions = { + dir: this.outDir, + format: this.name === 'client' ? 'app' : 'es', + // TODO: hmr_rebuild returns source map file when `sourcemap: true` + sourcemap: 'inline', + } + this.result = await this.instance.write(outputOptions) + + this.buildTimestamp = Date.now() + console.timeEnd(`[rolldown:${this.name}:build]`) + } + + async handleUpdate(ctx: HmrContext): Promise { + if (!this.result) { + return + } + const output = this.result.output[0] + if (!output.moduleIds.includes(ctx.file)) { + return + } + if (this.name === 'ssr') { + await this.build() + } else { + logger.info(`hmr '${ctx.file}'`, { timestamp: true }) + console.time(`[rolldown:${this.name}:hmr]`) + const result = await this.instance.experimental_hmr_rebuild([ctx.file]) + console.timeEnd(`[rolldown:${this.name}:hmr]`) + ctx.server.ws.send('rolldown:hmr', result) + } + } + + async import(input: string): Promise { + const output = this.result.output.find((o) => o.name === input) + assert(output, `invalid import input '${input}'`) + const filepath = path.join(this.outDir, output.fileName) + return import(`${pathToFileURL(filepath)}?t=${this.buildTimestamp}`) + } +} + +// TODO: use vite:build-html plugin +function viterollEntryPlugin( + config: ResolvedConfig, + viterollOptions: ViterollOptions, +): rolldown.Plugin { + const htmlEntryMap = new Map() + + return { + name: 'viteroll:entry', + transform: { + filter: { + id: { + include: [/\.html$/], + }, + }, + async handler(code, id) { + // process html (will be emiited later during generateBundle) + const htmlOutput = new MagicString(code) + htmlEntryMap.set(id, htmlOutput) + + let jsOutput = `` + if (viterollOptions?.reactRefresh) { + jsOutput += `import "virtual:react-refresh/entry";\n` + } + + // extract `, + ) + + // inject client + // (reuse /@vite/client for Websocket API) + htmlOutput.appendLeft( + htmlOutput.original.indexOf(``), + ` + + `, + ) + + this.emitFile({ + type: 'asset', + fileName: path.relative(config.root, htmlId), + originalFileName: htmlId, + source: htmlOutput.toString(), + }) + } + } + } + }, + } +} + +// TODO: workaround rolldownExperimental.reactPlugin which injects js to html via `load` hook +function reactRefreshPlugin(): rolldown.Plugin { + return { + name: 'react-hmr', + transform: { + filter: { + code: { + include: ['$RefreshReg$'], + }, + }, + handler(code, id) { + const output = new MagicString(code) + output.prepend(` + import * as __$refresh from 'virtual:react-refresh'; + const [$RefreshSig$, $RefreshReg$] = __$refresh.create(${JSON.stringify(id)}); + `) + output.append(` + __$refresh.setupHot(module.hot); + `) + return { code: output.toString(), map: output.generateMap() } + }, + }, + resolveId: { + filter: { + id: { + include: [/^virtual:react-refresh/], + }, + }, + handler: (source) => '\0' + source, + }, + load: { + filter: { + id: { + include: [/^\0virtual:react-refresh/], + }, + }, + async handler(id) { + const resolved = require.resolve('react-refresh/runtime') + if (id === '\0virtual:react-refresh/entry') { + return ` + import runtime from ${JSON.stringify(resolved)}; + runtime.injectIntoGlobalHook(window); + ` + } + if (id === '\0virtual:react-refresh') { + return ` + import runtime from ${JSON.stringify(resolved)}; + + export const create = (file) => [ + runtime.createSignatureFunctionForTransform, + (type, id) => runtime.register(type, file + '_' + id), + ]; + + function debounce(fn, delay) { + let handle + return () => { + clearTimeout(handle) + handle = setTimeout(fn, delay) + } + } + const debouncedRefresh = debounce(runtime.performReactRefresh, 16); + + export function setupHot(hot) { + hot.accept((prev) => { + debouncedRefresh(); + }); + } + ` + } + }, + }, + } +} diff --git a/playground/rolldown-dev-react/index.html b/playground/rolldown-dev-react/index.html new file mode 100644 index 00000000000000..c9ffedef072cbd --- /dev/null +++ b/playground/rolldown-dev-react/index.html @@ -0,0 +1,12 @@ + + + + + + Vite + React + TS + + +
+ + + diff --git a/playground/rolldown-dev-react/package.json b/playground/rolldown-dev-react/package.json new file mode 100644 index 00000000000000..e7521d1ae4b049 --- /dev/null +++ b/playground/rolldown-dev-react/package.json @@ -0,0 +1,16 @@ +{ + "name": "@vitejs/test-rolldown-react", + "private": true, + "type": "module", + "scripts": { + "dev": "vite" + }, + "dependencies": { + "react": "^18.3.1", + "react-dom": "^18.3.1" + }, + "devDependencies": { + "@types/react": "^18.3.11", + "@types/react-dom": "^18.3.1" + } +} diff --git a/playground/rolldown-dev-react/src/app.tsx b/playground/rolldown-dev-react/src/app.tsx new file mode 100644 index 00000000000000..24baf545c7e5e5 --- /dev/null +++ b/playground/rolldown-dev-react/src/app.tsx @@ -0,0 +1,16 @@ +import { useState } from 'react' + +export function App() { + const [count, setCount] = useState(0) + + return ( +
+

Vite + React

+
+ +
+
+ ) +} diff --git a/playground/rolldown-dev-react/src/main.tsx b/playground/rolldown-dev-react/src/main.tsx new file mode 100644 index 00000000000000..c443c03aa5db4f --- /dev/null +++ b/playground/rolldown-dev-react/src/main.tsx @@ -0,0 +1,9 @@ +import { StrictMode } from 'react' +import { createRoot } from 'react-dom/client' +import { App } from './app.tsx' + +createRoot(document.getElementById('root')!).render( + + + , +) diff --git a/playground/rolldown-dev-react/tsconfig.json b/playground/rolldown-dev-react/tsconfig.json new file mode 100644 index 00000000000000..e12edac8af75da --- /dev/null +++ b/playground/rolldown-dev-react/tsconfig.json @@ -0,0 +1,16 @@ +{ + "include": ["src", "*.ts"], + "compilerOptions": { + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "verbatimModuleSyntax": true, + "allowImportingTsExtensions": true, + "moduleResolution": "Bundler", + "module": "ESNext", + "target": "ESNext", + "lib": ["ESNext", "DOM"], + "jsx": "react-jsx", + "noEmit": true + } +} diff --git a/playground/rolldown-dev-react/vite.config.ts b/playground/rolldown-dev-react/vite.config.ts new file mode 100644 index 00000000000000..abf273dca18c5c --- /dev/null +++ b/playground/rolldown-dev-react/vite.config.ts @@ -0,0 +1,9 @@ +import { defineConfig } from 'vite' + +export default defineConfig({ + clearScreen: false, + experimental: { + rolldownDev: true, + rolldownDevReactRefresh: true, + }, +}) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f90d6f84d86216..24d25d1294bf91 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -233,9 +233,12 @@ importers: postcss: specifier: ^8.4.47 version: 8.4.47 + react-refresh: + specifier: ^0.14.2 + version: 0.14.2 rolldown: - specifier: https://pkg.pr.new/rolldown@1fa5d4b - version: https://pkg.pr.new/rolldown@1fa5d4b + specifier: 0.13.2-snapshot-a292401-20241105072341 + version: 0.13.2-snapshot-a292401-20241105072341 rollup: specifier: ^4.22.5 version: 4.22.5 @@ -1323,6 +1326,22 @@ importers: specifier: 0.10.64 version: 0.10.64 + playground/rolldown-dev-react: + dependencies: + react: + specifier: ^18.3.1 + version: 18.3.1 + react-dom: + specifier: ^18.3.1 + version: 18.3.1(react@18.3.1) + devDependencies: + '@types/react': + specifier: ^18.3.11 + version: 18.3.11 + '@types/react-dom': + specifier: ^18.3.1 + version: 18.3.1 + playground/self-referencing: {} playground/ssr: @@ -3052,64 +3071,64 @@ packages: '@polka/url@1.0.0-next.24': resolution: {integrity: sha512-2LuNTFBIO0m7kKIQvvPHN6UE63VjpmL9rnEEaOOaiSPbZK+zUOYIzBAWcED+3XYzhYsd/0mD57VdxAEqqV52CQ==} - '@rolldown/binding-darwin-arm64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-arm64@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-arm64@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-darwin-arm64@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-IvGCR1JGF55EM8t1HYgNyF7RNpf/lC5++WAWPmsdWcM6aDnc2ayWLVeEq/F5UCxJGGBnXDsPH8+FBMxBf/Ieag==} + cpu: [arm64] os: [darwin] - '@rolldown/binding-darwin-x64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-x64@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-x64@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-darwin-x64@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-OUbQy963o7pCdy1KnumyJUDY86dBQSdiektSpsOZOgyEB7tMTsd69EOAbqqyrxz2euQgDVveGJyD1GDgw2/ypg==} + cpu: [x64] os: [darwin] - '@rolldown/binding-freebsd-x64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-freebsd-x64@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-freebsd-x64@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-freebsd-x64@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-KWvitRouQ2J9ZRd+ioaJ4Aa+iXjqh8Ugf90RfwsSHTgX5P3b75lJbw19ObH4cranWAHyu1Z3Oz3m8Q5TfTIqpw==} + cpu: [x64] os: [freebsd] - '@rolldown/binding-linux-arm-gnueabihf@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm-gnueabihf@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm-gnueabihf@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-linux-arm-gnueabihf@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-fPgIOpmARKshz/ZWzTkfX/a1tUbU+3gedEUA9+Ry2d0yeKF8unnEvpvfw8FRh0Ht2Uq8X+cs54ZpQS37nlimfA==} + cpu: [arm] os: [linux] - '@rolldown/binding-linux-arm64-gnu@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-gnu@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-gnu@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-linux-arm64-gnu@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-oTgB9dXnFNNC1qxzbYwHLfnRViBxsQt7pPdCdpmbxZdcsQBQpSyqvf8IFU6VJn3GnBtJU0ysQ1s3BQ5TSSeNVQ==} + cpu: [arm64] os: [linux] - '@rolldown/binding-linux-arm64-musl@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-musl@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-musl@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-linux-arm64-musl@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-Q/F+iS43K6KXEB3LXwHoqxDbpude+vhC0P6Qp6HLctIksJf/2QreGTQ+aB0QVRwws2007MKJ4kYFi9ZpkfjG5A==} + cpu: [arm64] os: [linux] - '@rolldown/binding-linux-x64-gnu@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-gnu@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-gnu@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-linux-x64-gnu@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-SFSK2LkhuRJ6YDUHuSapZcuf7cp0tyQoO+1F3B+5Obu0s5CHv6HkkyJ/96GBvGCGEVXdtUNPKam32U+5Af4A9g==} + cpu: [x64] os: [linux] - '@rolldown/binding-linux-x64-musl@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-musl@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-musl@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-linux-x64-musl@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-OR6lEBRvFgXO2Zcr+WCWwhw9tl7S3ByVKBTEGV9ebeo0ScS4UtkChrsx13xJVOz5/o8dv0pYSV8c8OVatk/4jA==} + cpu: [x64] os: [linux] - '@rolldown/binding-wasm32-wasi@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-wasm32-wasi@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-wasm32-wasi@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-wasm32-wasi@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-OHewT4F6WjdFrbg56p/qByEU45ed5n+m4/NBHMwldQf7uxRS03urCI7WYRQcZe0H4Bl95cIQsPbjAQxBRzwlCw==} engines: {node: '>=14.21.3'} + cpu: [wasm32] - '@rolldown/binding-win32-arm64-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-arm64-msvc@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-arm64-msvc@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-win32-arm64-msvc@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-C09eFp4vjwzbfTwRBgScLIMNcey8dT1evcgb7dllkaurSONMRPweUrA8w+AjLoNLxmYtjo/8UXzy/WNAA9/9GA==} + cpu: [arm64] os: [win32] - '@rolldown/binding-win32-ia32-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-ia32-msvc@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-ia32-msvc@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-win32-ia32-msvc@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-nm9AH+s4LN/gUb2jNdr1E1nUCMFs/Cz2wcRn492LQHahDVBALDaY/VZGftqSp339tsMjaEZea+FzxmlTECGxCQ==} + cpu: [ia32] os: [win32] - '@rolldown/binding-win32-x64-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-x64-msvc@1fa5d4b': - resolution: {tarball: https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-x64-msvc@1fa5d4b} - version: 0.13.2 + '@rolldown/binding-win32-x64-msvc@0.13.2-snapshot-a292401-20241105072341': + resolution: {integrity: sha512-2YEn48I1RlOR4ATbVNqCjGvTPUbKbeUhtLT/+l++pJ5o6LwO3/RZMEB6J5mN5ZXQ2mXqpmbBOR06fY8tFThLSw==} + cpu: [x64] os: [win32] '@rollup/plugin-alias@5.1.1': @@ -6183,6 +6202,10 @@ packages: peerDependencies: react: ^18.3.1 + react-refresh@0.14.2: + resolution: {integrity: sha512-jCvmsr+1IUSMUyzOkRcvnVbX3ZYC6g9TDrDbFuFmRDq7PD4yaGbLKNQL6k2jnArV8hjYxh7hVhAZB6s9HDGpZA==} + engines: {node: '>=0.10.0'} + react@18.3.1: resolution: {integrity: sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==} engines: {node: '>=0.10.0'} @@ -6283,9 +6306,8 @@ packages: resolution: {integrity: sha512-l0OE8wL34P4nJH/H2ffoaniAokM2qSmrtXHmlpvYr5AVVX8msAyW0l8NVJFDxlSK4u3Uh/f41cQheDVdnYijwQ==} hasBin: true - rolldown@https://pkg.pr.new/rolldown@1fa5d4b: - resolution: {tarball: https://pkg.pr.new/rolldown@1fa5d4b} - version: 0.13.2 + rolldown@0.13.2-snapshot-a292401-20241105072341: + resolution: {integrity: sha512-WA2U4g9E+d/J1u/nAldwnxmE7KOOGxdnjg6GX/qsPekVqQ0e+dPV7qrGYWIBj3twjPFxdp+9bzsXrFW3LUhakQ==} hasBin: true rollup-plugin-dts@6.1.1: @@ -7113,6 +7135,10 @@ packages: peerDependencies: vue: ^3.2.0 + watchpack@2.4.2: + resolution: {integrity: sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==} + engines: {node: '>=10.13.0'} + web-streams-polyfill@3.2.1: resolution: {integrity: sha512-e0MO3wdXWKrLbL0DgGnUV7WHVuw9OUvL4hjgnPkIeEvESk74gAITi5G606JtZPp39cd8HA9VQzCIvA49LpPN5Q==} engines: {node: '>= 8'} @@ -8553,42 +8579,42 @@ snapshots: '@polka/url@1.0.0-next.24': {} - '@rolldown/binding-darwin-arm64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-arm64@1fa5d4b': + '@rolldown/binding-darwin-arm64@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-darwin-x64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-x64@1fa5d4b': + '@rolldown/binding-darwin-x64@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-freebsd-x64@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-freebsd-x64@1fa5d4b': + '@rolldown/binding-freebsd-x64@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-linux-arm-gnueabihf@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm-gnueabihf@1fa5d4b': + '@rolldown/binding-linux-arm-gnueabihf@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-linux-arm64-gnu@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-gnu@1fa5d4b': + '@rolldown/binding-linux-arm64-gnu@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-linux-arm64-musl@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-musl@1fa5d4b': + '@rolldown/binding-linux-arm64-musl@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-linux-x64-gnu@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-gnu@1fa5d4b': + '@rolldown/binding-linux-x64-gnu@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-linux-x64-musl@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-musl@1fa5d4b': + '@rolldown/binding-linux-x64-musl@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-wasm32-wasi@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-wasm32-wasi@1fa5d4b': + '@rolldown/binding-wasm32-wasi@0.13.2-snapshot-a292401-20241105072341': dependencies: '@napi-rs/wasm-runtime': 0.2.5 optional: true - '@rolldown/binding-win32-arm64-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-arm64-msvc@1fa5d4b': + '@rolldown/binding-win32-arm64-msvc@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-win32-ia32-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-ia32-msvc@1fa5d4b': + '@rolldown/binding-win32-ia32-msvc@0.13.2-snapshot-a292401-20241105072341': optional: true - '@rolldown/binding-win32-x64-msvc@https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-x64-msvc@1fa5d4b': + '@rolldown/binding-win32-x64-msvc@0.13.2-snapshot-a292401-20241105072341': optional: true '@rollup/plugin-alias@5.1.1(rollup@3.29.4)': @@ -11971,6 +11997,8 @@ snapshots: react: 18.3.1 scheduler: 0.23.2 + react-refresh@0.14.2: {} + react@18.3.1: dependencies: loose-envify: 1.4.0 @@ -12074,22 +12102,31 @@ snapshots: dependencies: glob: 10.4.5 - rolldown@https://pkg.pr.new/rolldown@1fa5d4b: + rolldown@0.13.2-snapshot-a292401-20241105072341: dependencies: + '@parcel/watcher': 2.4.1 + chokidar: 3.6.0(patch_hash=bckcfsslxcffppz65mxcq6naau) + connect: 3.7.0 + watchpack: 2.4.2 + ws: 8.18.0 zod: 3.23.8 optionalDependencies: - '@rolldown/binding-darwin-arm64': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-arm64@1fa5d4b - '@rolldown/binding-darwin-x64': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-darwin-x64@1fa5d4b - '@rolldown/binding-freebsd-x64': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-freebsd-x64@1fa5d4b - '@rolldown/binding-linux-arm-gnueabihf': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm-gnueabihf@1fa5d4b - '@rolldown/binding-linux-arm64-gnu': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-gnu@1fa5d4b - '@rolldown/binding-linux-arm64-musl': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-arm64-musl@1fa5d4b - '@rolldown/binding-linux-x64-gnu': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-gnu@1fa5d4b - '@rolldown/binding-linux-x64-musl': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-linux-x64-musl@1fa5d4b - '@rolldown/binding-wasm32-wasi': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-wasm32-wasi@1fa5d4b - '@rolldown/binding-win32-arm64-msvc': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-arm64-msvc@1fa5d4b - '@rolldown/binding-win32-ia32-msvc': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-ia32-msvc@1fa5d4b - '@rolldown/binding-win32-x64-msvc': https://pkg.pr.new/rolldown/rolldown/@rolldown/binding-win32-x64-msvc@1fa5d4b + '@rolldown/binding-darwin-arm64': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-darwin-x64': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-freebsd-x64': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-linux-arm-gnueabihf': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-linux-arm64-gnu': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-linux-arm64-musl': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-linux-x64-gnu': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-linux-x64-musl': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-wasm32-wasi': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-win32-arm64-msvc': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-win32-ia32-msvc': 0.13.2-snapshot-a292401-20241105072341 + '@rolldown/binding-win32-x64-msvc': 0.13.2-snapshot-a292401-20241105072341 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate rollup-plugin-dts@6.1.1(rollup@3.29.4)(typescript@5.6.2): dependencies: @@ -12993,6 +13030,11 @@ snapshots: '@vue/devtools-api': 6.6.4 vue: 3.5.12(typescript@5.6.2) + watchpack@2.4.2: + dependencies: + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + web-streams-polyfill@3.2.1: {} webidl-conversions@3.0.1: {}