MCPcopy Create free account
hub / github.com/arktypeio/arktype / builtIdOf

Function builtIdOf

ark/aot/unplugin.ts:2129–2134  ·  view source on GitHub ↗
(module: BuiltBundlerModule)

Source from the content-addressed store, hash-verified

2127// the file a module reads as a script. What isn't one is followed like a
2128// generated module, as a wasm module may import one
2129const builtIdOf = (module: BuiltBundlerModule): string | undefined => {
2130 const { resource } = module
2131 if (!resource || !isAbsolute(resource) || !isScriptModule(module)) return
2132 const file = fileOf(resource)
2133 return isAsset(file) ? undefined : file
2134}
2135
2136// Next.js's optimizePackageImports builds a package's entry as a module of
2137// re-exports for each set of names imported from it, so the bundle holds one

Callers 1

builtOfFunction · 0.85

Calls 3

fileOfFunction · 0.90
isAssetFunction · 0.90
isScriptModuleFunction · 0.85

Tested by

no test coverage detected