sigma-ui.config.json

Configuration for your project.

The sigma-ui.config.json config file is created during initialization. It holds SIGMA-UI configuration for your project.

You can create a sigma-ui.config.json file in your project by running the following command:

bash
npx sigma-ui init

See the CLI section for more information.

$schema

You can see the JSON Schema for sigma-ui.config.json here.

json
{
  "$schema": "https://sigma-ui.dev/schema.json"
}

Config options

typescript

This project and the components are written in TypeScript. It's highly recommended to use Typescript version of the components for your project as well.

You can set typescript to false to opt-out of TypeScript.

json
{
  "typescript": false
}

To configure import aliases in Javascript, you can add the following to your jsconfig.json file:

json
{
  "compilerOptions": {
    "paths": {
      "@/*": ["./*"]
    }
  }
}

style

This field determines the style system for the components (CSS or Tailwind).

json
{
  "style": "tailwind" | "css"
}

Try changing the style system and see how it affects the component's code:

Preview:

Create project

Deploy your new project in one-click.

tailwind

Skip this section if you're not using Tailwind style system.

This field helps CLI understand how Tailwind CSS is set up in your project. See installation page to learn how to set up Tailwind CSS.

tailwind.config

Path to your tailwind.config.js file.

json
{
  "tailwind": {
    "config": "tailwind.config.js" | "tailwind.config.ts"
  }
}

tailwind.css

Path to the CSS file that imports Tailwind CSS into your project.

json
{
  "tailwind": {
    "css": "src/assets/index.css"
  }
}

tailwind.baseColor

This is used to generate the default color palette for your components.

json
{
  "tailwind": {
    "baseColor": "gray" | "neutral" | "slate" | "stone" | "zinc"
  }
}

tailwind.cssVariables

You can choose between using CSS variables or Tailwind CSS utility classes for theming.

json
{
  "tailwind": {
    "cssVariables": `true` | `false`
  }
}

"cssVariables": true - can use both variables and utility classes. Variables are generated during initialization:

html
<Button class="bg-primary text-primary-foreground">Text</Button>
html
<Button class="bg-gray-900 text-gray-50">Text</Button>

"cssVariables": false - you can only use utility classes. The variables will not be generated:

html
<Button class="bg-gray-900 text-gray-50">Text</Button>

aliases

The CLI uses these values and the paths config from your tsconfig.json or jsconfig.json file to place generated components in the correct location.

Path aliases have to be set up in your tsconfig.json or jsconfig.json file. It will fallback to tsconfig.app.json if no paths were found in tsconfig.json

aliases.utils

Import alias for your utility functions.

json
{
  "aliases": {
    "utils": "@/lib/utils"
  }
}

aliases.components

Path to where CLI will add components.

json
{
  "aliases": {
    "components": "@/components"
  }
}
Edit this page on GitHub