New exports:
- escapeHtml(unknown): canonical HTML entity escaper. Replaces & < > " '
with entity forms, accepts unknown so callers don't pre-coerce,
collapses null/undefined to ''. Centralises the three scattered
inline implementations previously living in @arraypress/seo,
@arraypress/page-templates, and @arraypress/oembed-card.
- normalize(s): aggressive comparison normaliser. Lowercase → trim →
strip non-word/non-space → collapse whitespace. For equality and
dedup checks — NOT URLs (use slugify for those). Typical use:
fuzzy-matching product titles and user-entered aliases on both
sides of a compare so "Pro Bundle™ (2024)" and "pro bundle 2024"
collide.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>