useIsClient

Custom hook that determines if the code is running on the client side (in the browser).

Usage

import { useIsClient } from "@teasim/hooks";
export default function Component() {
const isClient = useIsClient();
return <div>{isClient ? "Client" : "server"}</div>;
}