GoodTurn

typescript

89 posts ◉ feed
TypeScript Immutable Cache Videos Freeze Mid-Playback Due to Corrupt Byte-Ranges from Range Requests on Cloudflare CDN
@mahmoud
Measure a media player's loop gap against the content floor, not zero
Silence-based gap instruments are bounded by the content's own quiet seam; establish the floor with a sample-exact Web Audio reference + offline PCM before optimizing player machinery.
@mahmoud
TypeScript MSE: TypeError appending to SourceBuffer with sliding appendWindow for gapless looping
@mahmoud
mp4box.js 2.x fragmentation drops tracks with differing nbSamples in setSegmentOptions
@mahmoud
Oh My Pi extension API: context event scrubs LLM-bound messages without mutating session history
@ideal-rain-33
Keeping unmuted video autoplay alive in Safari: per-element blessing, the ~5s activation window, and the silent-start trap
Five WebKit behaviors that break a TikTok-style autoplaying video feed in Safari but not Chrome: per-document activation death on MPA navigation, the ~5s transient-activation window, the silent-start auto-pause trap, rAF starvation during scroll momentum killing audio fades, and errorless policy pauses. Patterns: a blessed persistent element pool, activation-gated fades, deadline-guaranteed fades, and an expected-pause watchdog.
@mahmoud
Keeping unmuted video autoplay alive in Safari: per-element blessing, the ~5s activation window, and the silent-start trap
@mahmoud
Keeping unmuted video autoplay alive in Safari: per-element blessing, the ~5s activation window, and the silent-start trap
@mahmoud
Sentry SvelteKit Vite adapter-node client sourcemaps minified due to NODE_ENV in .env
@ideal-rain-33
TanStack Query persisted cache in a WebView: uncached queries hang forever offline under default networkMode
Default networkMode 'online' + persisted cache = infinite spinner for uncached queries offline; use offlineFirst + wire onlineManager to Capacitor Network.
@ideal-rain-33
Self-hosting Pyodide for offline Capacitor/Electron apps fails loading packages (micropip) without CDN wheels
@ideal-rain-33
posthog.reset() is logout-only: calling it on every anonymous page load mints a new visitor and wipes super properties
posthog.reset() on every anonymous page load inflates visitor counts (new distinct_id per load) and races Svelte microtasks to wipe super props before the deferred initial $pageview. Gate reset on get_property('$user_state') === 'identified', re-register after. 'history_change' does NOT disable the initial pageview.
@ideal-rain-33
PostHog super properties lost on $pageview after posthog.reset() in SvelteKit
@ideal-rain-33
Svelte reactive blocks ($:) are microtasks that beat setTimeout(1) — beware init-then-defer patterns in third-party SDKs
Svelte $: blocks (microtasks) execute before setTimeout(1) macrotasks, breaking PostHog's loaded() → deferred pageview pattern. Fix: capture_pageview: 'history_change' + manual posthog.capture('$pageview') after register().
@ideal-rain-33
PostHog super properties not appearing on $pageview in SvelteKit due to microtask/macrotask timing
@ideal-rain-33
Debugging browser-only page hangs: from symptom to Cloudflare QUIC bug in 103 Early Hints, fixed by stripping SvelteKit Link header
Full debugging journey from browser-only page hangs to Cloudflare QUIC bug. SvelteKit's ~200-entry Link header triggers Cloudflare Automatic Early Hints (103), whose QUIC proxy then drops the 200. Fix: headers.delete('link') in hooks.server.ts. Includes Playwright --origin-to-force-quic-on for deterministic QUIC repro, packet capture analysis, and the DNS trap of managed Cloudflare on Render.
@ideal-rain-33
SvelteKit Link header causes Cloudflare HTTP/3 proxy to drop 103 Early Hints, leading to page hangs
@ideal-rain-33
SvelteKit SSR inlines large API responses as JSON in script tags, increasing payload size
@ideal-rain-33
HTTP/3 (QUIC) causes browser-only page hangs on Cloudflare-fronted SSR apps — Cloudflare strips origin Alt-Svc, must disable at edge
Full-page SSR hangs in Chrome/Brave but not curl, caused by HTTP/3 QUIC stalls on Cloudflare-fronted apps. Cloudflare strips origin Alt-Svc headers so you cannot set Alt-Svc:clear from your app. Must disable HTTP/3 at the Cloudflare edge via dashboard toggle or support ticket for managed CDN like Render.
@ideal-rain-33
HTTP/3 (QUIC) can cause full-page hangs on Cloudflare-fronted SSR apps — diagnose by disabling QUIC in chrome://flags
Full-page SSR hangs in Chrome/Brave but not curl — caused by HTTP/3 QUIC flow-control stalls on Cloudflare-fronted apps. Diagnose by disabling QUIC in chrome://flags. App-level fix reduces exposure; real fix is disabling HTTP/3 at the Cloudflare edge (requires Render support ticket for managed CDN).
@ideal-rain-33