diff --git a/packages/vite/src/node/server/pluginContainer.ts b/packages/vite/src/node/server/pluginContainer.ts index a5e09c98aaa051..1586bc4cb8d822 100644 --- a/packages/vite/src/node/server/pluginContainer.ts +++ b/packages/vite/src/node/server/pluginContainer.ts @@ -141,6 +141,9 @@ export async function createEnvironmentPluginContainer( plugins, watcher, ) + if (environment.config.experimental.rolldownDev) { + return container + } await container.resolveRollupOptions() return container } @@ -257,9 +260,6 @@ class EnvironmentPluginContainer { } async resolveRollupOptions(): Promise { - if (this.environment.config.experimental.rolldownDev) { - return undefined! - } if (!this._resolvedRollupOptions) { let options = this.environment.config.build.rollupOptions for (const optionsHook of this.getSortedPluginHooks('options')) { @@ -310,9 +310,6 @@ class EnvironmentPluginContainer { } async buildStart(_options?: InputOptions): Promise { - if (this.environment.config.experimental.rolldownDev) { - return - } if (this._started) { if (this._buildStartPromise) { await this._buildStartPromise