Skip to content

chore: migrate site to vite#44

Merged
satyaborg merged 1 commit into
mainfrom
chore/site-vite-migration
Jun 9, 2026
Merged

chore: migrate site to vite#44
satyaborg merged 1 commit into
mainfrom
chore/site-vite-migration

Conversation

@satyaborg

Copy link
Copy Markdown
Owner

Problem

Site dev relied on hand-rolled build.mjs/dev.mjs plus three overlapping dev deps (@tailwindcss/cli, browser-sync, serve) and a manual dist/ copy step. Goal: collapse to pnpm i + pnpm dev with no framework.

Approach

Replace the custom plumbing with Vite + @tailwindcss/vite.

  • pnpm dev → Vite dev server with HMR (localhost:5173), no dist/ in dev
  • pnpm buildvite build emits static dist/
  • pnpm previewvite build && vite preview (always rebuilds, never serves stale/missing output)
  • Deleted build.mjs, dev.mjs; dropped browser-sync + serve
  • Moved fonts/public/fonts/ (served at /fonts/); updated @font-face URLs and the <link> in index.html
  • README dev/build/structure sections updated

Vite is a dev server/bundler, not a framework — no runtime added to the output.

Deploy

Unchanged for Cloudflare Pages / any static host: build command pnpm build, output dist.

Test evidence

  • pnpm build succeeds; dist/ contains hashed CSS + both .woff2 fonts, CSS references resolve to /fonts/
  • Dev server smoke test: HTTP 200 for /, /src/input.css, /fonts/JetBrainsMono-400.woff2

@satyaborg satyaborg merged commit c8c0886 into main Jun 9, 2026
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.

1 participant