A declarative setInterval: pass a delay to run a callback repeatedly, or null to pause, and the callback always sees the newest props and state.
pnpm dlx shadcn@latest add "https://ui.tealmac.com/r/use-interval.json"