(id: string)
| 13 | const getRegistry = () => (globalThis as any).__nsModules || (globalThis as any).__nsModuleRegistry || null; |
| 14 | |
| 15 | const accessor: VendorLookupFn = function (id: string): any { |
| 16 | if (!id) return undefined; |
| 17 | const manifest = getManifest(); |
| 18 | const registry = getRegistry(); |
| 19 | if (!manifest || !manifest.modules || !registry) return undefined; |
| 20 | // Direct match |
| 21 | if (registry.get && registry.get(id)) return registry.get(id); |
| 22 | // Try alias resolution |
| 23 | const alias = manifest.aliases?.[id]; |
| 24 | if (alias && registry.get && registry.get(alias)) return registry.get(alias); |
| 25 | return undefined; |
| 26 | }; |
| 27 | |
| 28 | Object.defineProperty(globalThis, '__nsVendor', { |
| 29 | value: accessor, |
nothing calls this directly
no test coverage detected