Skip to content

Commit 356ddfe

Browse files
authored
fix: update CJS interop error message (#11842)
1 parent d2c26ef commit 356ddfe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/vite/index.cjs

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ const unsupportedCJS = ['resolvePackageEntry', 'resolvePackageData']
2828
unsupportedCJS.forEach((name) => {
2929
module.exports[name] = () => {
3030
throw new Error(
31-
`"${name}" is not supported in CJS build of Vite 3.\nPlease use ESM or dynamic imports \`const { ${name} } = await import('vite')\`.`,
31+
`"${name}" is not supported in CJS build of Vite 4.\nPlease use ESM or dynamic imports \`const { ${name} } = await import('vite')\`.`,
3232
)
3333
}
3434
})

0 commit comments

Comments
 (0)