diff options
| author | Armand Philippot <git@armandphilippot.com> | 2023-10-27 11:09:38 +0200 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2023-11-11 18:15:27 +0100 |
| commit | 757201fdc5c04a3f15504f74bf8ab85bb6018c2b (patch) | |
| tree | 1adda54704314b24ec81bfdbf0c13acbce2cda87 /src/utils/hooks/index.ts | |
| parent | 3ab9f0423e97af63da4bf6a13ffd786955bd5b3b (diff) | |
refactor(hooks,provider): move reduce motion setter
Since the local storage key is not meant to change between the
components, it should be set directly inside the app file. So
both the local storage and the data attribute should be handle
in a provider.
I also added a custom document because we need a script to
retrieve the stored value in local storage earlier to avoid
flashing on hydration.
Diffstat (limited to 'src/utils/hooks/index.ts')
| -rw-r--r-- | src/utils/hooks/index.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/utils/hooks/index.ts b/src/utils/hooks/index.ts index cf8c01c..606c259 100644 --- a/src/utils/hooks/index.ts +++ b/src/utils/hooks/index.ts @@ -17,6 +17,7 @@ export * from './use-prism'; export * from './use-query-selector-all'; export * from './use-reading-time'; export * from './use-redirection'; +export * from './use-reduced-motion'; export * from './use-route-change'; export * from './use-scroll-position'; export * from './use-settings'; |
