toJSON() — ui Function Reference
Architecture documentation for the toJSON() function in errors.ts from the ui codebase.
Entity Profile
Dependency Diagram
graph TD 6a7eca04_1a30_b7d9_dacd_84826422d4a1["toJSON()"] f1db3a8d_16e3_e5f1_cd46_0a25f77561fd["RegistryError"] 6a7eca04_1a30_b7d9_dacd_84826422d4a1 -->|defined in| f1db3a8d_16e3_e5f1_cd46_0a25f77561fd style 6a7eca04_1a30_b7d9_dacd_84826422d4a1 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/shadcn/src/registry/errors.ts lines 63–74
toJSON() {
return {
name: this.name,
message: this.message,
code: this.code,
statusCode: this.statusCode,
context: this.context,
suggestion: this.suggestion,
timestamp: this.timestamp,
stack: this.stack,
}
}
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does toJSON() do?
toJSON() is a function in the ui codebase, defined in packages/shadcn/src/registry/errors.ts.
Where is toJSON() defined?
toJSON() is defined in packages/shadcn/src/registry/errors.ts at line 63.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free