use-config.ts — ui Source File
Architecture documentation for use-config.ts, a typescript file in the ui codebase. 4 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 1630452d_47ec_46b6_4efd_7b4f84de716c["use-config.ts"] cba8a664_3253_9b8c_8abe_9f0e33bbc037["jotai"] 1630452d_47ec_46b6_4efd_7b4f84de716c --> cba8a664_3253_9b8c_8abe_9f0e33bbc037 68f194ce_9060_f5f9_d266_dd66c3d544fb["utils"] 1630452d_47ec_46b6_4efd_7b4f84de716c --> 68f194ce_9060_f5f9_d266_dd66c3d544fb cde74491_5759_5f06_b202_504de1a24a1d["registry-base-colors"] 1630452d_47ec_46b6_4efd_7b4f84de716c --> cde74491_5759_5f06_b202_504de1a24a1d 9798186b_08af_1d79_2ad7_d662300dc0ba["registry-styles"] 1630452d_47ec_46b6_4efd_7b4f84de716c --> 9798186b_08af_1d79_2ad7_d662300dc0ba style 1630452d_47ec_46b6_4efd_7b4f84de716c fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { useAtom } from "jotai"
import { atomWithStorage } from "jotai/utils"
import { BaseColor } from "@/registry/registry-base-colors"
import { Style } from "@/registry/registry-styles"
type Config = {
style: Style["name"]
theme: BaseColor["name"]
radius: number
packageManager: "npm" | "yarn" | "pnpm" | "bun"
installationType: "cli" | "manual"
}
const configAtom = atomWithStorage<Config>("config", {
style: "new-york",
theme: "zinc",
radius: 0.5,
packageManager: "pnpm",
installationType: "cli",
})
export function useConfig() {
return useAtom(configAtom)
}
Domain
Subdomains
Functions
Types
Dependencies
- jotai
- registry-base-colors
- registry-styles
- utils
Source
Frequently Asked Questions
What does use-config.ts do?
use-config.ts is a source file in the ui codebase, written in typescript. It belongs to the ComponentRegistry domain, Styles subdomain.
What functions are defined in use-config.ts?
use-config.ts defines 1 function(s): useConfig.
What does use-config.ts depend on?
use-config.ts imports 4 module(s): jotai, registry-base-colors, registry-styles, utils.
Where is use-config.ts in the architecture?
use-config.ts is located at deprecated/www/hooks/use-config.ts (domain: ComponentRegistry, subdomain: Styles, directory: deprecated/www/hooks).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free