@vitejs/plugin-react 4.1.0 → 4.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -182,6 +182,8 @@ function viteReact(opts = {}) {
182
182
  root: projectRoot,
183
183
  filename: id,
184
184
  sourceFileName: filepath,
185
+ // Required for esbuild.jsxDev to provide correct line numbers
186
+ retainLines: !isProduction && isJSX && opts.jsxRuntime !== "classic",
185
187
  parserOpts: {
186
188
  ...babelOptions.parserOpts,
187
189
  sourceType: "module",
package/dist/index.mjs CHANGED
@@ -174,6 +174,8 @@ function viteReact(opts = {}) {
174
174
  root: projectRoot,
175
175
  filename: id,
176
176
  sourceFileName: filepath,
177
+ // Required for esbuild.jsxDev to provide correct line numbers
178
+ retainLines: !isProduction && isJSX && opts.jsxRuntime !== "classic",
177
179
  parserOpts: {
178
180
  ...babelOptions.parserOpts,
179
181
  sourceType: "module",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitejs/plugin-react",
3
- "version": "4.1.0",
3
+ "version": "4.1.1",
4
4
  "license": "MIT",
5
5
  "author": "Evan You",
6
6
  "contributors": [
@@ -38,10 +38,10 @@
38
38
  },
39
39
  "homepage": "https://github.com/vitejs/vite-plugin-react/tree/main/packages/plugin-react#readme",
40
40
  "dependencies": {
41
- "@babel/core": "^7.22.20",
41
+ "@babel/core": "^7.23.2",
42
42
  "@babel/plugin-transform-react-jsx-self": "^7.22.5",
43
43
  "@babel/plugin-transform-react-jsx-source": "^7.22.5",
44
- "@types/babel__core": "^7.20.2",
44
+ "@types/babel__core": "^7.20.3",
45
45
  "react-refresh": "^0.14.0"
46
46
  },
47
47
  "peerDependencies": {