Skip to content

Commit

Permalink
fix: 修正 node 依赖
Browse files Browse the repository at this point in the history
  • Loading branch information
cloudcome committed Jul 25, 2024
1 parent 33b73b8 commit 1c22816
Show file tree
Hide file tree
Showing 3 changed files with 564 additions and 626 deletions.
1,185 changes: 561 additions & 624 deletions dist/index.cjs

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"target": "ES2023",

// node18 https://node.green/#ES2023
"lib": ["ES2023", "DOM"],
"lib": ["ES2023"],
"plugins": [],
"types": ["vitest/globals"]
},
Expand Down
3 changes: 2 additions & 1 deletion vite.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,14 @@ export default defineConfig({
sourcemap: false,
copyPublicDir: false,
reportCompressedSize: false,
target: 'ES2023',
lib: {
entry: {
index: 'src/index.ts',
},
},
rollupOptions: {
external: [...builtinModules, 'node:*'],
external: [...builtinModules, ...builtinModules.map((m) => `node:${m}`)],
output: [
{
format: 'cjs',
Expand Down

0 comments on commit 1c22816

Please sign in to comment.