GeoLeaf Core API - v3.0.0
    Preparing search index...
    • Validates a URL destined for an img.src / a.href sink. Delegates to GeoLeaf.Security.validateUrl when present — that helper THROWS on unsafe input and returns the normalized URL on success, so the call is wrapped in a try/catch. When the seam is absent, a local fallback accepts only absolute http(s):// URLs. Returns null when the URL is unsafe — callers MUST skip rendering in that case.

      Parameters

      • url: unknown

        Candidate URL (any type; non-strings are rejected).

      Returns string | null

      The safe/normalized URL, or null when unsafe.