@vitejs/plugin-react
Advanced tools
Comparing version 2.0.0-alpha.3 to 2.0.0-beta.0
{ | ||
"name": "@vitejs/plugin-react", | ||
"version": "2.0.0-alpha.3", | ||
"version": "2.0.0-beta.0", | ||
"license": "MIT", | ||
@@ -30,3 +30,3 @@ "author": "Evan You", | ||
"engines": { | ||
"node": ">=14.6.0" | ||
"node": ">=14.18.0" | ||
}, | ||
@@ -43,3 +43,3 @@ "repository": { | ||
"dependencies": { | ||
"@babel/core": "^7.18.2", | ||
"@babel/core": "^7.18.5", | ||
"@babel/plugin-transform-react-jsx": "^7.17.12", | ||
@@ -49,7 +49,6 @@ "@babel/plugin-transform-react-jsx-development": "^7.16.7", | ||
"@babel/plugin-transform-react-jsx-source": "^7.16.7", | ||
"@rollup/pluginutils": "^4.2.1", | ||
"react-refresh": "^0.13.0" | ||
"react-refresh": "^0.14.0" | ||
}, | ||
"peerDependencies": { | ||
"vite": "^3.0.0-alpha" | ||
"vite": "^3.0.0-alpha.11" | ||
}, | ||
@@ -56,0 +55,0 @@ "devDependencies": { |
@@ -1,4 +0,4 @@ | ||
import fs from 'fs' | ||
import path from 'path' | ||
import { createRequire } from 'module' | ||
import fs from 'node:fs' | ||
import path from 'node:path' | ||
import { createRequire } from 'node:module' | ||
import type { types as t } from '@babel/core' | ||
@@ -5,0 +5,0 @@ |
@@ -1,6 +0,5 @@ | ||
import path from 'path' | ||
import path from 'node:path' | ||
import type { ParserOptions, TransformOptions, types as t } from '@babel/core' | ||
import * as babel from '@babel/core' | ||
import { createFilter } from '@rollup/pluginutils' | ||
import { normalizePath } from 'vite' | ||
import { createFilter, normalizePath } from 'vite' | ||
import type { Plugin, PluginOption, ResolvedConfig } from 'vite' | ||
@@ -94,3 +93,3 @@ import { | ||
// Provide default values for Rollup compat. | ||
let base = '/' | ||
let devBase = '/' | ||
let resolvedCacheDir: string | ||
@@ -122,4 +121,15 @@ let filter = createFilter(opts.include, opts.exclude) | ||
enforce: 'pre', | ||
config() { | ||
if (opts.jsxRuntime === 'classic') { | ||
return { | ||
esbuild: { | ||
logOverride: { | ||
'this-is-undefined-in-esm': 'silent' | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
configResolved(config) { | ||
base = config.base | ||
devBase = config.base | ||
projectRoot = config.root | ||
@@ -360,3 +370,3 @@ resolvedCacheDir = normalizePath(path.resolve(config.cacheDir)) | ||
attrs: { type: 'module' }, | ||
children: preambleCode.replace(`__BASE__`, base) | ||
children: preambleCode.replace(`__BASE__`, devBase) | ||
} | ||
@@ -363,0 +373,0 @@ ] |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
82280
7
2204
1
+ Addedreact-refresh@0.14.2(transitive)
- Removed@rollup/pluginutils@^4.2.1
- Removed@rollup/pluginutils@4.2.1(transitive)
- Removedestree-walker@2.0.2(transitive)
- Removedpicomatch@2.3.1(transitive)
- Removedreact-refresh@0.13.0(transitive)
Updated@babel/core@^7.18.5
Updatedreact-refresh@^0.14.0