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

# source.decorators

- **Type:**

```ts
type Decorators = {
  version?: 'legacy' | '2022-03';
};
```

- **Default:**

```ts
const defaultDecorators = {
  version: 'legacy';
};
```

Used to configure the decorators syntax.

:::warning
The usage of this configuration item is exactly the same as that of Rsbuild, but the default value is different. For detailed information, please refer to [Rsbuild - source.decorators](https://v2.rsbuild.rs/config/source/decorators).
:::

We found that most projects still use the `legacy` version of the decorator syntax, so the default value is `legacy`.
