Fix sidebar trigger hydration imports
This commit is contained in:
parent
ddbf019d12
commit
b1130c2a3d
1 changed files with 2 additions and 2 deletions
|
|
@ -260,9 +260,9 @@ function SidebarTrigger({
|
||||||
...props
|
...props
|
||||||
}: React.ComponentProps<typeof Button> & { fallback?: ReactNode }) {
|
}: React.ComponentProps<typeof Button> & { fallback?: ReactNode }) {
|
||||||
const { toggleSidebar } = useSidebar()
|
const { toggleSidebar } = useSidebar()
|
||||||
const [hydrated, setHydrated] = useState(false)
|
const [hydrated, setHydrated] = React.useState(false)
|
||||||
|
|
||||||
useEffect(() => {
|
React.useEffect(() => {
|
||||||
setHydrated(true)
|
setHydrated(true)
|
||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue