We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 78a99f4 commit 66c1421Copy full SHA for 66c1421
website/docs/zh/guide/basic/configure-rslib.mdx
@@ -129,7 +129,7 @@ rslib build -c rslib.prod.config.mjs
129
130
Rslib 提供了三种配置文件加载方式:
131
132
-- `jiti`:当你使用 `.ts`, `.mts` 和 `.cts` Rslib 会使用 [jiti](https://github.com/unjs/jiti) 来加载配置文件,提供 ESM 与 CommonJS 的互操作性,模块解析的行为与 Node.js 原生行为存在一定差异。
+- `jiti`:当你使用 `.ts`, `.mts` 和 `.cts` 后缀的配置文件时,Rslib 会使用 [jiti](https://github.com/unjs/jiti) 来加载配置文件,提供 ESM 与 CommonJS 的互操作性,模块解析的行为与 Node.js 原生行为存在一定差异。
133
- `native`:使用 Node.js 原生 loader 来加载配置文件,这可以保证模块解析的行为与 Node.js 原生行为一致,并且性能更好。这要求你使用的 JavaScript 运行时已经原生支持 TypeScript。
134
135
例如,Node.js 从 v22.6.0 开始已经原生支持 TypeScript,你可以运行如下命令来使用 Node.js 原生 loader 来加载配置文件:
0 commit comments