useOnline
Track whether the user currently has a network connection.
useOnline.tsx
import { useOnline } from "@cermuel/hooks/react";export function UseOnlineExample() { const online = useOnline(); return <p>You are currently {online ? "online" : "offline"}.</p>;}Props
Param
Type
Default Value
No props for this hook
Returns
boolean