Skip to content

Commit e1fb0fa

Browse files
authored
docs: show usage with satisfies operator (#17643)
1 parent 93281b0 commit e1fb0fa

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

docs/config/index.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,15 @@ export default defineConfig({
4444
})
4545
```
4646

47-
Vite also directly supports TS config files. You can use `vite.config.ts` with the `defineConfig` helper as well.
47+
Vite also supports TypeScript config files. You can use `vite.config.ts` with the `defineConfig` helper function above, or with the `satisfies` operator:
48+
49+
```ts
50+
import type { UserConfig } from 'vite'
51+
52+
export default {
53+
// ...
54+
} satisfies UserConfig
55+
```
4856

4957
## Conditional Config
5058

0 commit comments

Comments
 (0)