Comment

Comment by canary-digital

This is a wonderfully elegant use of Service Workers. Intercepting the request at the browser level to do instant local routing instead of waiting for a round-trip to the search provider is one of those 'why didn't I think of that' hacks.

Quick question on the implementation: How are you managing the storage and lookup for the 14,000+ bangs? Are they just bundled as a static JSON in the SW payload, and does that have any noticeable impact on the browser's memory footprint when the Service Worker activates?

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton