Skip to content

Commit

Permalink
Merge pull request #59 from vite-plugin/v0.10.2
Browse files Browse the repository at this point in the history
v0.10.2
  • Loading branch information
yejimeiming authored Sep 15, 2024
2 parents af875ed + 01be384 commit 4f0a307
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## 0.10.2 (2023-09-15)

- 7704cd4 chore: add comments
- 5c3e702 bugfix #54
- 5e3294e docs: add commonjs.zh-CN.md link
- ff77d51 feat: add commonjs.zh-CN.md, commonjs.jpg

## 0.10.1 (2023-11-14)

- 492aab3 fix(#42): auto-increment dynamic require id
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vite-plugin-commonjs",
"version": "0.10.1",
"version": "0.10.2",
"description": "A pure JavaScript implementation of CommonJs",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/__snapshots__/exports.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* [vite-plugin-commonjs] export-runtime-S */ var module = { exports: {} }; var exports = module.exports; /* [vite-plugin-commonjs] export-runtime-E *//* [vite-plugin-commonjs] import-hoist-S */ import * as __CJS__import__0__ from "./dynamic"; /* [vite-plugin-commonjs] import-hoist-E */
const { hello, world } = __CJS__import__0__.default || __CJS__import__0__
const { hello, world } = (__CJS__import__0__.default || __CJS__import__0__)

// ❌ `exports` exported members are dynamic.
// import { cjs } from './cjs'
Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/__snapshots__/main.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* [vite-plugin-commonjs] import-hoist-S */ import * as __CJS__import__0__ from "./exports"; /* [vite-plugin-commonjs] import-hoist-E */const { msg: message } = __CJS__import__0__.default || __CJS__import__0__;
/* [vite-plugin-commonjs] import-hoist-S */ import * as __CJS__import__0__ from "./exports"; /* [vite-plugin-commonjs] import-hoist-E */const { msg: message } = (__CJS__import__0__.default || __CJS__import__0__);
import cjs from "./cjs";
document.querySelector("#app").innerHTML = `
<pre>
Expand Down

0 comments on commit 4f0a307

Please sign in to comment.