Make dismissed reactive ($state) to clear the Svelte build warning

dismissed.size is read in the template (the History 'Clear' control), so the Set
must be $state for Svelte 5 to track .add()/reassignment. Build is warning-clean
again. Frontend only — rebuild + refresh.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
jay
2026-05-31 17:08:58 +00:00
parent 68a401eed6
commit 9d257c9950
+2 -2
View File
@@ -26,8 +26,8 @@
const BRIEF_VIEW_KEY = 'goodnews:brief_view'; // {date, items} — the reader's curated brief
const HISTORY_CAP = 200;
let seenIds = new Set();
let dismissed = new Set();
let seenIds = new Set(); // handler-only, not rendered — no reactivity needed
let dismissed = $state(new Set()); // read in the template (Clear button) — must be reactive
let history = $state([]);
function persistSession() {