work

trasta.dev

A blog-first personal site, rebuilt on TanStack Start and Cloudflare Workers.

TanStack StartCloudflare WorkersMDXReact
trasta.dev

The site you are looking at now. The previous version was built with Astro + Panda CSS, and i rewrote it from scratch so writing the blog felt a little more natural day-to-day.

design themes

  • don't get in the way of the writing. Whitespace and typography first, decoration only at the edges.
  • bilingual ja / en. Browser language picks the entry point, a lang cookie remembers it. Each post has paired ja/en MDX.
  • external posts in the same list. Posts on trap.jp or Zenn live in the same blog index, so the timeline is complete regardless of where i wrote.
  • a quiet tiger. Small motion-effect PNGs sit by section titles and the footer, never in the body text.

stack

  • TanStack Start (SSR + file-based routing)
  • Cloudflare Workers (host; server.ts handles the language routing)
  • @mdx-js/rollup + remark-gfm / rehype-shiki (MDX content with dual-theme syntax highlighting)
  • react-tweet (lightweight SWR-based tweet embeds)
  • Plain CSS (variables + clamp() for dark / light)

small details

  • Accept-Language q-values are parsed; only the highest-priority ja* tag stays on /. Everything else (and missing headers) redirects to /en/....
  • A lang cookie remembers the user's pick for a year and overrides the header.
  • Blog frontmatter has an externalUrl; the index renders those entries as <a target="_blank">, and the detail route 404s. So external + internal posts share one feed.
  • Code blocks are highlighted with both github-light and github-dark-dimmed; CSS variables flip them with the theme.
  • View transitions are subtle, and prefers-reduced-motion is respected.