Skip to content
quarry Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 6339776ac8c78d87fb4ef446665d5a134de6d506433211790f04c42800c21503
Ticket: 548788c1a4b6d97f5f5585e299c789f931fff11a
Evaluate Datastar Pro for the fleet filter's URL sync
User & Date: dmestas on 2026-08-27 10:55:06
Changes

  1. Untracked field cmimetype: "text/x-markdown"
  2. comment changed to:
    The fleet filter on `/` is the one URL-sync case our hand-rolled `syncurl` helper cannot cover, and it is the only concrete reason to consider Datastar Pro.
    
    ## Why syncurl stops here
    
    `syncurl` (internal/web/web.go) works by reading the clicked anchor's own `href` — the real, cold-loadable route — and replaceState-ing to it. That works for the diff toggle and the doc tabs because both are anchors already carrying a real URL.
    
    The fleet filter is not an anchor. It is `<form method="get" action="/">` with a debounced search input plus `kind` and `sort` selects (fleetSource). Without JS it navigates to `/?q=...&kind=...&sort=...`; with JS it fires `@get('/fleet.frag', {contentType: 'form'})` and the address bar never moves. The URL we would want is the serialization of three controls, which no href-reading trick can produce — we would have to build the query string from form state on every change.
    
    ## What Pro offers
    
    `data-query-string` syncs signals to query params on change and back on load, with a `__history` modifier. Verified 2026-08-26 against data-star.dev/reference/attributes. Also `data-replace-url`, a thinner version of what syncurl already does for us.
    
    Pro is a one-time lifetime licence: $349 solo, $1,299 team (up to 25 employees). It also carries the Inspector, which is plausibly worth more day to day than the attribute — debugging SSE patches by eye is the real pain in this stack.
    
    ## Why this is Low
    
    One affected surface. The filter works correctly today; you simply cannot link to a filtered fleet view or restore one on reload, and the no-JS path already does the right thing. Nothing is broken, and hand-rolling query-string assembly stays available if we decide the surface matters more than the licence.
    
    ## What would raise it
    
    More form-shaped filter surfaces. The current inventory is exactly one. At three or four, buying beats hand-rolling.
    
    ## Notes
    
    - The load-side half of `data-query-string` is largely redundant here: quarry is server-rendered and every one of these routes already reads its own query string, so the server owns URL-to-state.
    - Whichever way this goes, the fleet input must use replaceState, not pushState — it is debounced, and pushState would stack a history entry per keystroke burst.
    - Related: the strata `url-sync-helper` / `url-sync-doctabs` covers the two anchor-shaped cases. This ticket is only about the form-shaped one.
    
  3. priority changed to: "Low"
  4. severity changed to: "Minor"
  5. status changed to: "Open"
  6. subsystem changed to: "web"
  7. title changed to:
    Evaluate Datastar Pro for the fleet filter's URL sync
    
  8. type changed to: "Feature_Request"