Tag: inertiajs
Just a quick snippet about how to do polling the Svelte way. ``js
import { onDestroy } from "svelte" let interval const poll = () => {
clearTimeout(interval)
Inertia.reload()
interval = setTimeout(poll, 1000)
} poll() onDestroy(() => clearTimeout(interval))
`` I mean, it co...