Lynx/Modules/Zero DaisyUI/Installation
@sigx/lynx-zero-daisyui · Beta

Installation#

Add @sigx/lynx-zero-daisyui to your project.

Install the package#

Terminal
pnpm add @sigx/lynx-zero @sigx/lynx-zero-daisyui

Import it once#

Import the module and the stylesheet at the app entry, before anything renders:

TSX
import '@sigx/lynx-zero-daisyui';                 // seeds themes + axis defaults
import '@sigx/lynx-zero-daisyui/css/index.css';   // the compiled skin

The module import has side effects on purpose: it registers the themes and axis defaults at load, before the first ZeroRoot renders. Keep both imports, even if a bundler reports the first as unused.

Then wrap the app in ZeroRoot, and turn on enableCSSInheritance in the Lynx build plugin. See @sigx/lynx-zero installation.

Verify#

TSX
import '@sigx/lynx-zero-daisyui';
import { listThemes } from '@sigx/lynx-zero';

console.log(listThemes().map((t) => t.name)); // ['light', 'dark', 'dim', 'nord', 'sunset']