Skip to content

Commit af4e16d

Browse files
authored
fix(rsc): replace 'rolldownVersion' in this.meta with 'rolldownVersion' in vite for Vite 6 compat (#761)
1 parent 72c7a87 commit af4e16d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/plugin-rsc/src/plugin.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { pathToFileURL } from 'node:url'
66
import { createRequestListener } from '@remix-run/node-fetch-server'
77
import * as esModuleLexer from 'es-module-lexer'
88
import MagicString from 'magic-string'
9+
import * as vite from 'vite'
910
import {
1011
type BuilderOptions,
1112
type DevEnvironment,
@@ -1269,7 +1270,7 @@ function customOptimizerMetadataPlugin({
12691270
environments: {
12701271
client: {
12711272
optimizeDeps:
1272-
'rolldownVersion' in this.meta
1273+
'rolldownVersion' in vite
12731274
? ({
12741275
rolldownOptions: {
12751276
plugins: [optimizerPluginRolldown()],

0 commit comments

Comments
 (0)