Use <SignedIn /> to control the rendering of components for users. Components inside <SignedIn /> are only rendered if the user is authenticated.

import { NhostProvider, SignedIn } from '@nhost/react'
import { nhost } from '@/utils/nhost'

function Page() {
  return (
    <NhostProvider nhost={nhost}>
      <SignedIn>
        <h1>Only rendered if the user is authenticated</h1>
      </SignedIn>
    </NhostProvider>
  )
}

Parameters


__namedParameters required { children: ReactNode }