News
Technical documentation for the News app — a client-side news aggregator with classification, clustering, and trending.
Data Flow
api.jsfetches headlines from public RSS sources.classifier.jsassigns each story to a category using a lightweight on-device classifier.clustering.jsgroups duplicate or related stories.trending-engine.jsranks stories by recency and engagement signals.search-index.jsbuilds a client-side index (MiniSearch) for instant keyword search.
Refresh Strategy
refresh.js polls sources on a timer, updates the freshness badge, and re-renders the story grid without a full page reload.
Service Worker
sw.js uses a network-first strategy for data requests (fresh headlines when online, cached stories when offline) and cache-first for the app shell.
Design System
All styling uses the root design tokens from /assets/css/base.css.