> For AI agents: the complete documentation index is available at /next/zh/llms.txt, the full documentation bundle is available at /next/zh/llms-full.txt.

# output.distPath

> `optional` **distPath?**: `DistPathConfig`

:::info Lynx 默认值覆盖
此项是 Rsbuild 配置，`pluginLynx` 覆盖了它的默认值。下方默认值指应用插件后的值。请在 `rsbuild.config.ts` 顶层配置，显式设置的值优先。

[完整行为见 Rsbuild 配置参考](https://rsbuild.rs/zh/config/output/dist-path)。
:::

设置产物文件的目录。

## Default Value

使用 Rsbuild 默认的 distPath 配置，并设置 `root: 'dist'`。

## Remarks

更多选项请参考 [Rsbuild - distPath](https://rsbuild.rs/config/output/dist-path)。

## Example

使用 `output` 代替 `dist`（默认值）：

```js
import { defineConfig } from '@lynx-js/rspeedy'
export default defineConfig({
  output: {
    distPath: {
      root: './output',
    },
  },
})
```
