vite-plugin-commonjs
Advanced tools
Comparing version 0.7.0 to 0.7.1
@@ -175,3 +175,3 @@ "use strict"; | ||
return; | ||
if (!(node.left.object.type === "Identifier" && ["module", "exports"].includes(node.left.object.name))) | ||
if (!["module", "exports"].includes(node.left.object.name)) | ||
return; | ||
@@ -373,3 +373,3 @@ analyzed.exports.push({ | ||
_config.optimizeDeps.esbuildOptions.plugins.push({ | ||
name: "vite-plugin-dynamic-import:pre-bundle", | ||
name: "vite-plugin-commonjs:pre-bundle", | ||
setup(build) { | ||
@@ -376,0 +376,0 @@ build.onLoad({ filter: /.*/ }, async ({ path: id }) => { |
{ | ||
"name": "vite-plugin-commonjs", | ||
"version": "0.7.0", | ||
"version": "0.7.1", | ||
"description": "A pure JavaScript implementation of CommonJs", | ||
@@ -26,3 +26,3 @@ "main": "./dist/index.js", | ||
"types": "tsc", | ||
"prepublishOnly": "npm run test && npm run build" | ||
"prepublishOnly": "npm run build && npm run test" | ||
}, | ||
@@ -32,3 +32,3 @@ "dependencies": { | ||
"fast-glob": "^3.2.12", | ||
"vite-plugin-dynamic-import": "^1.3.2" | ||
"vite-plugin-dynamic-import": "^1.4.0" | ||
}, | ||
@@ -52,2 +52,2 @@ "devDependencies": { | ||
] | ||
} | ||
} |
@@ -63,3 +63,3 @@ # vite-plugin-commonjs | ||
// `node_modules` is exclude by default, so we need to include it explicitly | ||
// https://github.com/vite-plugin/vite-plugin-commonjs/blob/v0.7.0/src/index.ts#L123-L125 | ||
// https://github.com/vite-plugin/vite-plugin-commonjs/blob/v0.7.0/src/index.ts#L125-L127 | ||
if (id.includes('node_modules/xxx')) { | ||
@@ -66,0 +66,0 @@ return true |
@@ -63,3 +63,3 @@ # vite-plugin-commonjs | ||
// 默认会排除 `node_modules`,所以必须显式的包含它explicitly | ||
// https://github.com/vite-plugin/vite-plugin-commonjs/blob/v0.7.0/src/index.ts#L123-L125 | ||
// https://github.com/vite-plugin/vite-plugin-commonjs/blob/v0.7.0/src/index.ts#L125-L127 | ||
if (id.includes('node_modules/xxx')) { | ||
@@ -66,0 +66,0 @@ return true |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
43841