docs: fix code block formatting for `usePreviewMode` (#26303)

This commit is contained in:
Florian Lefebvre 2024-03-17 16:17:07 +01:00 committed by GitHub
parent 68f7d4df8b
commit cfd34ec234
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 2 deletions

View File

@ -24,7 +24,8 @@ export function useMyPreviewMode () {
return !!route.query.customPreview return !!route.query.customPreview
} }
}); });
}``` }
```
### Modify default state ### Modify default state
@ -40,7 +41,7 @@ const { enabled, state } = usePreviewMode({
}) })
``` ```
::alert{icon=👉} ::note
The `getState` function will append returned values to current state, so be careful not to accidentally overwrite important state. The `getState` function will append returned values to current state, so be careful not to accidentally overwrite important state.
:: ::