import { URLPattern } from "urlpattern-polyfill"; type UrlPatternPolyfillGlobal = Omit & { URLPattern?: typeof URLPattern; }; const globals = globalThis as UrlPatternPolyfillGlobal; globals.URLPattern ??= URLPattern;