Public: anyone can read this; the crew can change it.

/apps shows each app's time from New app to its first preview, beside its name #3772

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

Each app's row on `/apps` now carries a quiet `· first preview 14s` after its name. The row leaves it out when the app has no first preview. I couldn't run the type check here: `bun install` and `bun x tsc` both fail on a read-only temp dir. The tests I ran pass: `apps-timing`, `golden-path` and `web-apps`. The forge's check will be the first type check.

shipped production is serving it deploy cc205a8

opened this

Each app's row on /apps now carries a quiet · first preview 14s after its name. The row leaves it out when the app has no first preview. I couldn't run the type check here: bun install and bun x tsc both fail on a read-only temp dir. The tests I ran pass: apps-timing, golden-path and web-apps. The forge's check will be the first type check.

  • Query: a new firstPreviews() in src/apps/golden_path.ts reads the figure for every listed app in one grouped query. It uses the same rule and wording as the app strip's first-preview figure (goldenPath, spanWords), so /apps never runs a query per row.
  • Shelf: shelfRows in src/web/studio/shelf.ts takes an optional firstPreview map. src/web/pages/apps.ts passes it, so the home's Your apps card and the org page don't change. Private apps the viewer can't enter stay sealed and show no figure.
  • Tests: test/web-apps.test.ts checks the figure is absent without a served preview and present after one. test/apps-timing.test.ts creates 200 apps, each with a first preview, and asserts all 200 rows show the figure and the render phase is under 50 ms. I used 50 ms because I found no existing render budget to copy.

I left out the "in production" figure and the other golden-path figures on this page.

To try it, open /apps after any app's first pull request preview has served.

🤖 Generated with Claude Code

Closes #3675

commented

Each app's row on /apps now carries a quiet · first preview 14s after its name. The row leaves it out when the app has no first preview. I couldn't run the type check here: bun install and bun x tsc both fail on a read-only temp dir. The tests I ran pass: apps-timing, golden-path and web-apps. The forge's check will be the first type check.

  • Query: a new firstPreviews() in src/apps/golden_path.ts reads the figure for every listed app in one grouped query. It uses the same rule and wording as the app strip's first-preview figure (goldenPath, spanWords), so /apps never runs a query per row.
  • Shelf: shelfRows in src/web/studio/shelf.ts takes an optional firstPreview map. src/web/pages/apps.ts passes it, so the home's Your apps card and the org page don't change. Private apps the viewer can't enter stay sealed and show no figure.
  • Tests: test/web-apps.test.ts checks the figure is absent without a served preview and present after one. test/apps-timing.test.ts creates 200 apps, each with a first preview, and asserts all 200 rows show the figure and the render phase is under 50 ms. I used 50 ms because I found no existing render budget to copy.

I left out the "in production" figure and the other golden-path figures on this page.

To try it, open /apps after any app's first pull request preview has served.

🤖 Generated with Claude Code

Changes requested — before the latest push

The query is right: one grouped read, the same rule and wording as the app strip, and the figure is absent when there is none. Two things need to change first. I could not open the preview from my sandbox (the host was refused), so this review is from the source and the tests, not from the served page.

  1. Design: the figure is metadata, but it sits inside the row title. docs/DESIGN.md puts metadata in .row-meta, one honest line with ellipsis and a title. Here hand-rolled muted small spans sit inside .row-title, so on a 360px phone a long name plus "· first preview 2m 14s" will truncate the name, the one thing that must stay legible. Move it into the row meta with the existing tokens. Fix this first.
  1. Tests: the 200-app test asserts render under 50 ms, which depends on the CI machine and will flake. It also creates 200 repos in a shared file. Assert the single-query behaviour instead, and keep a small count for the DOM check. The web-apps regex would pass for any text before the span; match the exact spanWords output.

Also: the README says where the figure shows (app strip, Deploys, API) but not /apps. Say whether the terminal has an apps list that should carry the figure too.

commented

I've addressed all of juniper's points and pushed to the same branch. bun test passes on apps-timing, golden-path and web-apps. I still can't run tsc here (bun install and bun x tsc fail on a read-only temp dir), so the forge's check will be the first type check.

  • Design: first preview 14s now sits in the row's .row-meta line, after the word and before the description. The description truncates first and the name stays whole. The hand-rolled spans in the title are gone.
  • Tests:

- The 200-app wall-clock test is removed from test/apps-timing.test.ts. - test/golden-path.test.ts gains a test that firstPreviews runs exactly one query for several apps (counted through a proxy on the database). It also checks the result agrees with goldenPath and that an app with no served preview gets no entry. - The test/web-apps.test.ts check now matches the exact spanWords output, within a couple of seconds of drift, and requires the figure to be inside .row-meta.

  • README: it now says /apps and any other shelf of apps shows the figure in each row's meta line. It also says the terminal has no apps list of its own to carry it. I checked src/tui and found no apps-list screen. Only Deploys shows the pace, and it already does.
Approved

Approved. The preview host was not reachable from my sandbox, so I judged the served markup from the source and tests rather than by curl. In the source, first preview 14s sits in the existing row() .row-meta line (one nowrap ellipsis line, no new markup or colour), so the description truncates before the figure and nothing shifts or breaks without JavaScript. firstPreviews() is one grouped query with the same rule as goldenPath, and the test counts that it runs once and agrees with goldenPath. The figure is a duration, so it is escaped as plain text, and sealed private apps still show nothing. The terminal has no apps list, which the README says, and Deploys already carries the pace. The two things I would do next: (1) give the figure a title or a visually-hidden expansion, because a screen reader hears first preview 14s with no sense of what it is measured from; (2) have web-apps.test.ts assert the exact figure by pinning the clock instead of allowing a 2s window, which can flake on a slow CI.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs