Home / Function/ getRegistriesIndex() — ui Function Reference

getRegistriesIndex() — ui Function Reference

Architecture documentation for the getRegistriesIndex() function in api.ts from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  66758d64_c0d9_99aa_1f60_b8d2cae68e87["getRegistriesIndex()"]
  c41eed12_c415_48c8_bcf4_9d09d3424a18["api.ts"]
  66758d64_c0d9_99aa_1f60_b8d2cae68e87 -->|defined in| c41eed12_c415_48c8_bcf4_9d09d3424a18
  bde2daf4_2e0d_0ce9_896b_95c29a0c42cd["getRegistries()"]
  66758d64_c0d9_99aa_1f60_b8d2cae68e87 -->|calls| bde2daf4_2e0d_0ce9_896b_95c29a0c42cd
  style 66758d64_c0d9_99aa_1f60_b8d2cae68e87 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/shadcn/src/registry/api.ts lines 309–316

export async function getRegistriesIndex(options?: { useCache?: boolean }) {
  // Fetch new format and transform to old Record<string, string> for backward compatibility.
  const registries = await getRegistries(options)
  if (!registries) return null
  return Object.fromEntries(registries.map((r) => [r.name, r.url])) as z.infer<
    typeof registriesIndexSchema
  >
}

Subdomains

Frequently Asked Questions

What does getRegistriesIndex() do?
getRegistriesIndex() is a function in the ui codebase, defined in packages/shadcn/src/registry/api.ts.
Where is getRegistriesIndex() defined?
getRegistriesIndex() is defined in packages/shadcn/src/registry/api.ts at line 309.
What does getRegistriesIndex() call?
getRegistriesIndex() calls 1 function(s): getRegistries.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free