Skip to content

feat(ssr): extract shared Astro CSS - #282

Open
tenphi wants to merge 3 commits into
mainfrom
codex/astro-shared-css-extraction
Open

feat(ssr): extract shared Astro CSS#282
tenphi wants to merge 3 commits into
mainfrom
codex/astro-shared-css-extraction

Conversation

@tenphi

@tenphi tenphi commented Aug 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • add opt-in shared CSS extraction to the Astro integration via css: { mode: 'extract' }
  • expose ordered collector artifacts and preserve page-local CSS and cascade order
  • support every collector artifact kind: property, font-face, counter-style, function, raw, global, chunk, and keyframes
  • emit deterministic content-hashed assets with Astro base and build.assets support
  • preserve CSP nonces on extracted links and recognize link-only SSR output during client global-style deduplication
  • add unit coverage plus an Astro production-build fixture for zero-client-JS static pages
  • document the integration and include a minor changeset

Verification

  • pnpm typecheck
  • pnpm lint
  • pnpm format
  • pnpm format:check
  • pnpm build
  • pnpm size
  • pnpm test (79 files, 2,128 tests)
  • pnpm check:test-only
  • pnpm knip
  • production fixture extracts all eight artifact kinds and keeps a route-only keyframe inline
  • production-tested on all 8 tenphi.me routes: identical selected computed styles, pseudo-elements, geometry, text, and element counts across 4,043 elements; no console errors
  • tenphi.me payload comparison: 29.1% less raw HTML+CSS and 14.1% less gzip than inline delivery

@github-actions

github-actions Bot commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

📦 Snapshot release

Published 0.0.0-snapshot.94a5096.

pnpm add @tenphi/tasty@0.0.0-snapshot.94a5096

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