Skip to content

Commit 8e4fdd3

Browse files
authored
docs: now @acidify/core is ESM
1 parent 8f13c30 commit 8e4fdd3

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

packages/docs/content/core/nodejs.md

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,6 @@ npm install @acidify/core
1212

1313
`@acidify/core` 包含完整的 TypeScript 类型定义,因此可以在 TypeScript 项目中使用。
1414

15-
<details>
16-
17-
<summary>为什么 build.gradle.kts 中写了 useEsModule(),但发布的包还是 CommonJS 模块?</summary>
18-
19-
这是 Ktor 目前[尚未解决的一个问题](https://youtrack.jetbrains.com/issue/KTOR-9082)。Ktor 的代码中使用了 `eval("require")("node:net")` 的方式来动态加载 Node.js 内置模块,而这种写法在 CommonJS 模块中才能工作。我们在构建中使用了 `useEsModule()` 来生成 ES 模块版本的包,但由于这个问题,最终发布的包仍然是通过 ESBuild 转换成的 CommonJS 模块。
20-
21-
</details>
22-
2315
## 使用示例
2416

2517
`@acidify/core` 包导出的类型和 API 与 Kotlin 版本的 `acidify-core` 基本保持一致,但在其他方面有一些重要的区别:

0 commit comments

Comments
 (0)