components.json
The local config file that tells the CLI where to put installed source.
What it is
components.json lives in the consumer project, not in the Vinyaas registry. It records the style name, whether the project uses TypeScript, which Tailwind stylesheet to expect, and the path aliases the installed files import.
Why it exists
Installed components import cn from @/lib/utils and sit under components/ui. The CLI reads components.json so those paths match the project instead of a fixed template.
Fields
$schema— optional JSON Schema URL for editor validation.style— the registry style to request. Vinyaas shipsnew-york.tsx— whether installed files use TypeScript.tailwind— CSS entry path and related Tailwind settings.vinyaas initwrites theme tokens into that stylesheet for Tailwind CSS v4.aliases— import aliases for components, utils, ui, and lib.
Example
A realistic Next.js app config:
{
"$schema": "https://vinyaas.vercel.app/schema/components.json",
"style": "new-york",
"tsx": true,
"tailwind": {
"css": "app/globals.css",
"baseColor": "neutral",
"cssVariables": true
},
"aliases": {
"components": "@/components",
"utils": "@/lib/utils",
"ui": "@/components/ui",
"lib": "@/lib"
}
}Registry vs components.json
The registry publishes one JSON item per component. That item is the source of truth for the component file and its npm dependencies. components.json is local project configuration. It does not list every component and it is not published with the registry. Installed component state is tracked separately in .vinyaas/manifest.json after a successful vinyaas add.
Flow: components.json (consumer config) → vinyaas init / vinyaas add → registry catalog and items → source files in your project.
How init and add use it
vinyaas init creates components.json when the file is missing. A later init does not overwrite an existing file. vinyaas add reads the aliases and style from that file. Init also prepares the configured CSS path, aliases, and utilities. See the CLI guide for commands and flags.