You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@vitejs/plugin-react

Package Overview
Dependencies
Maintainers
4
Versions
79
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vitejs/plugin-react - npm Package Compare versions

Comparing version
4.5.2
to
4.6.0
+12
-1
dist/index.cjs

@@ -144,5 +144,6 @@ 'use strict';

const jsxImportDevRuntime = `${jsxImportSource}/jsx-dev-runtime`;
let runningInVite = false;
let isProduction = true;
let projectRoot = process.cwd();
let skipFastRefresh = false;
let skipFastRefresh = true;
let runPluginOverrides;

@@ -186,2 +187,3 @@ let staticBabelOptions;

configResolved(config) {
runningInVite = true;
projectRoot = config.root;

@@ -212,2 +214,11 @@ isProduction = config.isProduction;

},
options(options) {
if (!runningInVite) {
options.jsx = {
mode: opts.jsxRuntime,
importSource: opts.jsxImportSource
};
return options;
}
},
transform: {

@@ -214,0 +225,0 @@ filter: {

@@ -128,5 +128,6 @@ import { dirname, join } from 'node:path';

const jsxImportDevRuntime = `${jsxImportSource}/jsx-dev-runtime`;
let runningInVite = false;
let isProduction = true;
let projectRoot = process.cwd();
let skipFastRefresh = false;
let skipFastRefresh = true;
let runPluginOverrides;

@@ -170,2 +171,3 @@ let staticBabelOptions;

configResolved(config) {
runningInVite = true;
projectRoot = config.root;

@@ -196,2 +198,11 @@ isProduction = config.isProduction;

},
options(options) {
if (!runningInVite) {
options.jsx = {
mode: opts.jsxRuntime,
importSource: opts.jsxImportSource
};
return options;
}
},
transform: {

@@ -198,0 +209,0 @@ filter: {

+10
-4
{
"name": "@vitejs/plugin-react",
"version": "4.5.2",
"version": "4.6.0",
"license": "MIT",

@@ -36,3 +36,4 @@ "author": "Evan You",

"patch-cjs": "tsx ../../scripts/patchCJS.ts",
"prepublishOnly": "npm run build"
"prepublishOnly": "npm run build",
"test-unit": "vitest run"
},

@@ -55,3 +56,3 @@ "engines": {

"@babel/plugin-transform-react-jsx-source": "^7.27.1",
"@rolldown/pluginutils": "1.0.0-beta.11",
"@rolldown/pluginutils": "1.0.0-beta.19",
"@types/babel__core": "^7.20.5",

@@ -65,4 +66,9 @@ "react-refresh": "^0.17.0"

"@vitejs/react-common": "workspace:*",
"unbuild": "^3.5.0"
"babel-plugin-react-compiler": "19.1.0-rc.2",
"react": "^19.1.0",
"react-dom": "^19.1.0",
"rolldown": "1.0.0-beta.19",
"unbuild": "^3.5.0",
"vitest": "^3.2.4"
}
}