Projects BibleWeb Bookmarks Chapter-level bookmarks
Done

Chapter-level bookmarks

Area: Bookmarks Milestone: v1

Context

Problem: Readers want to mark chapters they're studying or plan to return to — a digital equivalent of placing a physical bookmark in a Bible.

Solution: A simple bookmark system that lets users mark entire chapters. Bookmarks are stored in localStorage (no server, no account required) and available on the free tier.

Not included: Verse-level bookmarks, bookmark folders, or bookmark notes. This is a minimal "mark this chapter" feature.

Functional

Users can bookmark any chapter and see their bookmarks listed on a dedicated page.

User flow:

  1. User clicks a verse → context menu → "Bookmark"
  2. The current chapter is bookmarked with a timestamp
  3. User can view all bookmarks at /bookmarks
  4. Clicking a bookmark navigates to that chapter
  5. User can remove bookmarks from the list

Edge cases:

  • Chapter-level granularity only (bookmarking from any verse in a chapter bookmarks the chapter)
  • No duplicate bookmarks — if the chapter is already bookmarked, it's a no-op or toggles
  • No limit on number of bookmarks (free tier feature)
  • Bookmarks persist across sessions via localStorage

UX & Design

Bookmark action: Available in the verse context menu as "Bookmark" with a bookmark icon.

No visual indicator in the reader — unlike notes, bookmarked chapters don't show a visual marker in the text.

Technical

Storage: Entirely client-side — localStorage under key bibleweb_bookmarks. No API, no database table.

Data shape: Array<{ bookId: number, chapter: number, createdAt: string }>

Store (bookmarks.svelte.ts):

  • initBookmarks() — reads and JSON-parses from localStorage on mount
  • addBookmark(bookId, chapter) — pushes to array + persist() (localStorage.setItem)
  • removeBookmark(bookId, chapter) — filters array + persists
  • isBookmarked(bookId, chapter) — O(n) linear scan
  • getAllBookmarks() — returns sorted copy by createdAt DESC

Files:

  • apps/web/src/lib/stores/bookmarks.svelte.ts — bookmark store + persistence

Status

Current: DONE Milestone: v1 Priority: Medium — simple but frequently used

History:

  • BibleGame had a bookmark system
  • Web version simplified to localStorage-only for the free tier

Dependencies:

  • Requires: nothing (standalone localStorage feature)
  • Used by: bookmarks list page (DONE)

Screenshots

Feature screenshot