Files
shakespeare/src
Alex Gleason 317c923532 Fix font @font-face runtime error by stripping esm.sh /* from asset URLs
Root cause of the Tailwind v4 'Missing closing } at font-face' runtime
error: font assets imported via a CSS @import (e.g. @fontsource packages)
were emitted as url(https://esm.sh/*@fontsource/...woff2). The /* from
esm.sh's wildcard ('externalize all deps') prefix sits inside an unquoted
url(), and the in-browser Tailwind v4 tokenizer misreads it as the start of
a CSS comment, scanning past the rule's closing } and throwing.

esm.sh's '*' only affects JS module builds; for raw static assets it is
meaningless and the same file is served without it. Strip the '/*' prefix
from externalized asset URLs (and ?url asset imports) so emitted CSS url()
values are parseable by all CSS parsers, not just the ones tolerant of
'/*' inside url(). JS module URLs are untouched.

Adds unit tests for stripAssetUrlWildcard.
2026-06-05 10:34:38 -05:00
..
2025-12-20 18:29:00 -06:00