8000 dts 出现构建内存溢出 · Issue #1325 · egoist/tsup · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

dts 出现构建内存溢出 #1325

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
ChineseStars opened this issue Mar 27, 2025 · 1 comment
Open

dts 出现构建内存溢出 #1325

ChineseStars opened this issue Mar 27, 2025 · 1 comment
8000

Comments

@ChineseStars
Copy link
ChineseStars commented Mar 27, 2025

tsup@8.4.0

DTS Build start
node:events:502
throw er; // Unhandled 'error' event
^

Error [ERR_WORKER_OUT_OF_MEMORY]: Worker terminated due to reaching memory limit: JS heap out of memory
at [kOnExit] (node:internal/worker:313:26)
at Worker..onexit (node:internal/worker:229:20)
Emitted 'error' event on Worker instance at:
at [kOnExit] (node:internal/worker:313:12)
at Worker..onexit (node:internal/worker:229:20) {
code: 'ERR_WORKER_OUT_OF_MEMORY'
}

Node.js v22.12.0

构建 dts 出现错误

配置如下
{
format: ['esm'],
dts: true,
splitting: true,
bundle: false,
tsconfig: './tsconfig.lib.json',
}

@thresh111
Copy link

在 defineConfig 中 的 dts 选项设置 entry ,只生成一个 dts 文件就可以了,

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0