Skip to content

Conversation

@metonym
Copy link
Owner

@metonym metonym commented Oct 22, 2025

#386 added a LanguageName utility type.

Similar to #387, this applies the utility type to the languageName prop in LangTag to improve DX. The widened string literal union trick is used to afford autocomplete while allowing any string.

This also adds an e2e test for LangTag. Even though LangTag is an abstraction (not intended to be used directly), it's still worth adding a test case.

@metonym metonym changed the title Langtag languagename type feat(types): LangTag types languageName prop using LanguageName utility type Oct 22, 2025
@metonym metonym force-pushed the langtag-languagename-type branch from 71586b2 to 37dc4a5 Compare October 22, 2025 02:46
@metonym metonym temporarily deployed to langtag-languagename-type - svelte-highlight PR #388 October 22, 2025 02:46 — with Render Destroyed
@metonym metonym merged commit a24cd3e into master Oct 22, 2025
2 checks passed
@metonym metonym deleted the langtag-languagename-type branch October 22, 2025 02:48
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