Skip to content

chore: Update the toolchain and dependencies, and move to cn - #155

Merged
eve0415 merged 26 commits into
mainfrom
feat/not-found-view-transition
Oct 14, 2026
Merged

eve0415 merged 26 commits into
mainfrom
feat/not-found-view-transition

Conversation

@eve0415

@eve0415 eve0415 commented Oct 14, 2026

Copy link
Copy Markdown
Owner

Updates the runtime, toolchain, dependencies, compatibility date and workflows, and replaces clsx + tailwind-merge with cn. It also carries two refactors already on this branch: the 404 search result driven by <ViewTransition>, and a useMemo in the sky that React Compiler already covers.

Changes

  • Node.js 24.21.0 and pnpm 12.11.2. Every dependency is on its newest version that passes pnpm's minimum release age, exact-pinned. @cloudflare/vitest-plugin moves from the pkg.pr.new preview build to the npm release, so the workspace overrides are gone.
  • compatibility_date moves to 2026-10-06. The two flags that flip in that window, spec_compliant_dispatch_exceptions and durable_object_io_tasks_prevent_eviction, touch nothing in the Worker's server code.
  • The worker vitest project disables vitest's file module cache, which workerd cannot read. It can go once [vitest-plugin] Fix filesystem module caching cloudflare/workers-sdk#16163 ships.
  • Workflows: pnpm/setup v3.1.1, upload-artifact v7.0.2, ubuntu-26.04-arm, and the obsolete update-pnpm: next-12 input dropped.
  • cn: the cn/vite plugin compiles the merge tables into src/lib/cn-tables.gen.ts, which is gitignored. pnpm generate writes the same file from cn-tables.config.ts, and CI and the update workflow run it before lint. pnpm generate now types Env from .dev.vars.example everywhere.
  • tw() marker tests: the identity-binding assertion only ever matched @tanstack/react-store's useSelector default, and it was already failing on main. Its replacement checks every tw() call and bare tw reference in src under stripTw's import rule, and requires each marked list to ship as a bare string.

For review

🤖 Generated with Claude Code

https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6

eve0415 and others added 15 commits September 17, 2026 21:17
The compiler emits the same memo slots for the inlined loop, so the manual hook only restated what it already does.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
React coordinates the capture, so the feature guard and the flushSync around the state update both go. The reduced-motion path now skips the transition rather than animating at zero duration.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Workerd cannot read the host-side cache that vitest 5 enables by default.
Scoped to the worker project so dist and source keep the cache.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
It matched third-party code, not a tw() marker.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Reads each literal tw() argument from src and checks the bundle holds it bare, never as a call.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
cn/vite compiles the merge tables into the ignored cn-tables.gen.ts; pnpm generate writes it from the same options before lint and tests.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Reads each tw() use from src under stripTw's import rule and checks the bundle holds every list bare.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Copilot AI balanced review requested due to automatic review settings October 14, 2026 00:36
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-14T01:30:16.322723Z bbde8dc New commits
🔒 Security Review ✅ Completed 2026-10-14T01:30:34.055868Z bbde8dc New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://feat-not-found-view-transition-website.eve0415.workers.dev (commit bbde8dc)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://7e40ae10-website.eve0415.workers.dev bbde8dc 2026-10-14T01:26:53.817Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://8dfda97d-website.eve0415.workers.dev c55db81 2026-10-14T00:48:28.686Z Visit the dashboard ↗
  • Build: Failed ❌

View logs ↗
f6186ec 2026-10-14T00:46:34.386Z View logs ↗

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f6186ecbe5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

{/* Triggers the capture; `none` keeps the container itself out of
it, so only the named children below animate, as they did under
the hand-rolled `document.startViewTransition`. */}
<ViewTransition default='none'>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Enable the update trigger on this ViewTransition

When a non-reduced-motion search completes, startTransition(apply) relies on this boundary to start the browser capture, but React defines default='none' as disabling every trigger that is not explicitly configured. Because no update prop is provided and this is the only React ViewTransition boundary, document.startViewTransition is not activated; the manually named result line and chips therefore pop in instead of running the existing transition animations.

Useful? React with 👍 / 👎.

@eve0415 eve0415 changed the title Update the toolchain and dependencies, and move to cn chore: Update the toolchain and dependencies, and move to cn Oct 14, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

It combines a wide runtime/compatibility‑date/dependency bump (including a Durable Object eviction flag change and a library migration) whose correctness depends on running the full build/test/e2e gate, which cannot be verified here.

0 open findings

What changed in this PR

This PR is a broad, meticulously‑documented maintenance update for the eve0415.net personal site. It bumps the Node.js/pnpm runtime, compatibility date, dependencies and CI workflows, and migrates the cn class‑merge helper from clsx + tailwind-merge to the cn package (whose cn/vite plugin compiles merge tables into a gitignored src/lib/cn-tables.gen.ts). It also folds in two pre‑existing branch refactors: the 404 search result now uses React 19's <ViewTransition> instead of a hand‑rolled document.startViewTransition + flushSync, and a now‑unnecessary useMemo in the star field is removed.

Changes:

  • Toolchain/deps: Node 24.21.0, pnpm 12.11.2, compatibility_date 2026‑10‑06, ubuntu-26.04-arm, pinned dependency bumps, and @cloudflare/vitest-plugin moved from a pkg.pr.new preview to the npm release (removing workspace overrides).
  • cn migration: new cn-tables.config.ts, pnpm generate and CI now build the cn tables before lint; the generated file is excluded from gitignore/lint/fmt/coverage.
  • Refactors + test rework: 404 <ViewTransition> conversion, star‑field useMemo removal, and a rewritten tw-markers.test.ts that walks real tw() imports/calls via the oxc AST instead of the obsolete identity‑binding assertion.
File Description
wrangler.json Advances compatibility_date to 2026‑10‑06.
vitest.config.ts Disables fsModuleCache for workerd; excludes cn-tables.gen.ts from coverage.
vite.config.ts Adds the cn/vite plugin and imports cnOptions.
tsconfig.json Adds cn-tables.config.ts to the include list.
cn-tables.config.ts New cn build options + a runnable import.meta.main generator.
src/​lib/​cn.ts Replaces clsx+tailwind-merge with createCn(tables).
src/​lib/​cn.test.ts Switches ClassValue import to cn; adds CSS‑var/size cases.
test/​dist/​tw-markers.test.ts Rewrites marker checks around real imports/calls + bundle verdicts.
test/​source/​{strip-tw,plugin-harness}.ts Comment/count updates only.
src/​routes/​.../​not-found/​index.tsx Converts to React <ViewTransition> + startTransition.
src/​routes/​.../​sky/​star-field.tsx Removes the compensating useMemo.
src/​routes/​.../​site-header.tsx, comet-link.tsx, home/​hero.tsx Tailwind class canonicalizations (scrollbar-none, animate-[…], calc spacing).
package.json, pnpm-workspace.yaml, .node-version Dependency/runtime pins; removes preview overrides.
oxlint.config.ts, oxfmt.config.ts, .gitignore Ignore the generated cn tables file.
.github/​workflows/​{ci,update}.yaml pnpm generate, action pin bumps, runner image bump.
.devcontainer/​* Image and feature version bumps.
AGENTS.md Documentation/count updates for the cn switch and toolchain.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c55db8168a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread wrangler.json
Comment on lines +13 to +15
"placement": {
"mode": "smart"
},

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep the explicit empty Cron trigger list

When pnpm deploy targets an environment that still has the former hourly and weekly schedules—for example, one upgraded directly from the pre-rebuild release—omitting triggers will not remove them. Cloudflare specifies that undefined triggers or crons leaves deployed triggers in place, while disabling them requires crons: []; those schedules would therefore continue invoking a Worker whose src/server.ts no longer exports a scheduled handler. Restore the explicit empty trigger list removed after this block. Cloudflare Cron Trigger documentation

Useful? React with 👍 / 👎.

Comment thread wrangler.json Outdated
"version_metadata": {
"binding": "CF_VERSION_METADATA"
},
"previews": {}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Configure the email binding for Worker Previews

When Workers Builds runs wrangler preview for a non-production branch, this empty block does not inherit the top-level bindings; Cloudflare explicitly requires preview bindings to be declared under previews. Consequently, even after the preview's Turnstile and address secrets are configured, CONTACT_EMAIL remains absent, so a valid contact submission reaches env.CONTACT_EMAIL.send() in send-contact.ts, throws, and is returned as send-failed. Add a preview send_email binding and the corresponding preview settings, or avoid enabling a preview flow whose contact form cannot work. Cloudflare Worker Preview configuration

Useful? React with 👍 / 👎.

eve0415 and others added 6 commits October 14, 2026 10:02
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Vite's native config loader rejects extensionless relative imports.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
A Preview only gets the Durable Object bindings declared under previews.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
eve0415 and others added 4 commits October 14, 2026 10:16
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Node.js compatibility is on by default from compatibility date 2026-08-04.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Qe4qPEEZguMBNMhaU8ecs6
@eve0415
eve0415 merged commit 3bc361d into main Oct 14, 2026
5 checks passed
@eve0415
eve0415 deleted the feat/not-found-view-transition branch October 14, 2026 01:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants