Skip to content
Eskais UI

Get started

Installation

Eskais UI is a shadcn registry: components arrive in your project as source you own, with their UI SDK, Tailwind and token dependencies.

Requirements

  • React 19 and React DOM 19 or newer.
  • Tailwind CSS v4.
  • A components.json from npx shadcn@latest init -b base -p nova (the flags skip its questions). Registry code runs in the browser and in any Node project, with npm, pnpm or Bun: it imports nothing from Bun or Node.

1. Add the registry

Add @eskais to registries once. The URL pins the latest release through refs/tags/, so a branch with the same name can never stand in for the tag; change the tag to upgrade, or use main for unreleased changes.

components.json
{  "$schema": "https://ui.shadcn.com/schema.json",  "style": "new-york",  "tsx": true,  "tailwind": { "css": "src/index.css", "baseColor": "neutral", "cssVariables": true },  "aliases": {    "components": "@/components",    "ui": "@/components/ui",    "utils": "@/lib/utils",    "lib": "@/lib",    "hooks": "@/hooks"  },  "registries": {    "@eskais": "https://raw.githubusercontent.com/p-otero/eskais-ui/refs/tags/v0.2.20/public/r/{name}.json"  }}

2. Make the aliases resolve

shadcn writes registry:ui files to aliases.ui and registry:lib files to aliases.lib, and rewrites the registry's @/components/ui, @/lib and @/lib/utils imports to yours, so any prefix works (~/components/ui, #ui…). Set all four: components, ui, utils and lib.

Put the paths in the root tsconfig.json
shadcn reads only the root tsconfig.json: it ignores tsconfig.app.json and references, and writes into a literal @/ folder when an alias doesn't resolve. Vite's template keeps its paths in tsconfig.app.json, so copy them up.
tsconfig.json
{  "files": [],  "references": [{ "path": "./tsconfig.app.json" }],  "compilerOptions": {    "baseUrl": ".",    "paths": { "@/*": ["./src/*"] }  }}

Subpath imports instead of paths

Subpath imports in package.json work instead of paths, with no bundler alias: Node, TypeScript and Vite all read them. Set the aliases to #components, #ui, #lib/utils, #lib and #hooks.

package.json
{  "imports": {    "#components/*": "./src/components/*",    "#ui/*": "./src/components/ui/*",    "#lib/*": "./src/lib/*",    "#hooks/*": "./src/hooks/*"  }}

shadcn then writes imports with their extension (#ui/button.tsx, #lib/utils.ts), because Node resolves subpath imports to exact files, so add "allowImportingTsExtensions": true to compilerOptions (it needs noEmit, as in Vite's template) and write your own imports the same way: import { Button } from "#ui/button.tsx".

Keep the extension out of the mapping. ui holds .ts files next to the .tsx ones (form-context.ts, every *-primitive.ts), so a mapping that appends one, like "#ui/components/*": "./src/components/ui/*.tsx", can't reach them: shadcn writes #ui/components/form-context with no extension, and it resolves to a .tsx file that doesn't exist.

A flat layout

A ui/ folder isn't required. To keep every component in src/components, point both aliases at that folder; the aliases stay the same.

package.json
{  "imports": {    "#components/*": "./src/components/*",    "#ui/*": "./src/components/*",    "#lib/*": "./src/lib/*",    "#hooks/*": "./src/hooks/*"  }}

Between components, shadcn writes imports through the first alias that matches, components: form-actions.tsx imports #components/form-context.ts. Both aliases resolve to the same file, so your own code can import either way.

3. Declare the UI SDK layer

Put @layer ui-sdk; first in your global stylesheet, above @import "tailwindcss", so your utilities win over UI SDK's behaviour CSS.

src/index.css
@layer ui-sdk;@import "tailwindcss";/* shadcn adds the theme's tokens, base rules and @custom-variant dark below. */

4. Add components

npx shadcn@latest add @eskais/theme @eskais/font-geist @eskais/button

Dependencies come along: a component brings the parts it's built from, the theme and utils.

  • theme brings utils, whose cn knows the theme's utilities. Merge classes with it: a plain tailwind-merge drops text-meta from cn("text-meta", "text-muted-foreground"). If shadcn init already wrote lib/utils.ts, add with --overwrite.
  • font-geist bundles Geist and Geist Mono from npm (no font CDN). Without it the theme falls back to the system font. font-inter is the alternative.

Running shadcn

  • Runner. Every command here uses npx shadcn@latest. With pnpm, run pnpm dlx shadcn@latest; with Bun, bunx shadcn@latest.
  • Package manager. shadcn installs dependencies with the manager it finds from your lockfile, or from packageManager in package.json. In a pnpm project without a lockfile yet, set "packageManager": "pnpm@<version>", or shadcn falls back to npm.
  • Windows paths with a dotted folder. shadcn 4.23.0 on Windows drops everything after a folder whose name starts with a dot, so a project under C:\Users\me\.config\app gets its files written to C:\Users\me\. Run shadcn from a path without dotted folders, or map the project to a drive letter first: subst X: C:\Users\me\.config\app, then run it from X:\ (subst X: /d removes the mapping).

While UI SDK is in beta

  • With npm, shadcn add writes a caret range for @ui-sdk/*. Change it to the exact version the registry pins, since later betas can break. pnpm and Bun keep the exact version.
  • pnpm 11+ refuses packages younger than minimumReleaseAge, and so does Bun when bunfig.toml sets one. Every other dependency the registry pins is at least 7 days old, but UI SDK's first release is from 2026-11-12: until its pinned beta is old enough, add @ui-sdk/core and @ui-sdk/react to minimumReleaseAgeExclude in pnpm-workspace.yaml or to minimumReleaseAgeExcludes under [install] in bunfig.toml.

5. Connect the appearance

Dark mode, density and palettes are attributes on <html>. Create the appearance once, apply it before the first render, and keep it in sync with Appearance. See Theming.

src/main.tsx
import { Appearance, createAppearance } from "@/components/ui/appearance"
const appearance = createAppearance({ colorScheme: "system" })appearance.apply()
createRoot(root).render(  <Appearance appearance={appearance}>    <App />  </Appearance>,)

Optional: lint rules

npx shadcn@latest add @eskais/lint-rules adds an oxlint config with the react and ui-tailwind presets of @p-otero/oxlint-rules (hook and React Compiler checks, spacing role tokens) and the @shadcn/lint design-system rules (no-restyle, no-raw-colors, no-arbitrary-values…), plus eskais/icon-button-needs-label, which flags an icon-only Button or Toggle without size="icon" and an aria-label, and eskais/scroll-area as a warning, which flags a bare overflow-auto, overflow-y-auto or -scroll class so scrolling content goes in a ScrollArea, and eskais/no-inline-icons as a warning, which flags a hand-drawn <svg> (all three come as eskais-oxlint-plugin.js beside the config). Extend it from your .oxlintrc.json.

The components you install carry oxlint-disable comments for this config's rules, each with its reason, so lint them with a config that extends eskais-ui.oxlintrc.json. Under another config, those comments disable rules it doesn't run, and reportUnusedDisableDirectives reports each one. In a monorepo whose root .oxlintrc.json doesn't extend it, either extend it from the root, or add "**/components/ui/**" to the root's ignorePatterns and lint the app's components with a config that extends it.

It carries no type-aware rules, which need oxlint --type-aware and oxlint-tsgolint. The components you install pass typescript/no-unsafe-type-assertion and typescript/restrict-template-expressions, so you can turn both on in a type-aware config and lint them with your own code. The few casts they need go through assumeType, keysOf and recordOf from lib/narrow, each with its reason.

Optional: test helpers

npx shadcn@latest add @eskais/test-utils adds Testing Library queries that skip UI SDK's live regions: getToast, queryToasts, queryAlerts, ignoreAnnouncer and resetAnnouncer for your test setup.

Test unreleased items

To try a branch before it is released, serve its built registry and point @eskais at it, so every item and the @eskais/* items it depends on come from the branch. In a checkout of the branch, build the registry (public/r) and serve that folder over HTTP:

npx serve public/r -l 4173# or, with Node alone:node -e "require('http').createServer((q, s) => require('fs').createReadStream('public/r' + new URL(q.url, 'http://x').pathname).on('error', () => s.writeHead(404).end()).pipe(s)).listen(4173)"
components.json
{  "registries": {    "@eskais": "http://localhost:4173/{name}.json"  }}

Then add as usual: npx shadcn@latest add @eskais/command. Switch the URL back to the release when you're done.

  • One item can also come from a file, by a relative path: npx shadcn@latest add ../eskais-ui/public/r/command.json. Its @eskais/* dependencies still come from the @eskais URL in components.json, so with the release URL there they pull the released versions back over the branch's. Serve the folder to test a set of items together.
  • On Windows, shadcn 4.23 can't read an absolute path: C:/…/command.json fails with "unknown scheme" and file:///C:/…/command.json with "not implemented". Use a relative path or HTTP.

Next steps

  1. Pick your colours and density.
  2. Create the agent bridge so agents can operate your UI with approval.
  3. Browse the components.

Using an AI coding agent?

Install the skills with Vercel's skills CLI: they teach your agent the conventions on this site, from spacing roles to the agent test every interface gets, and land in .agents/skills. See Agent skills for what each one covers and how to point Claude Code, Codex or Cursor at them.

npx skills@1.8.1 add p-otero/eskais-ui@v0.2.20 --full-depth --skill eskais-ui --skill eskais-perf --skill eskais-mockup -a universal -y

To show a screen before building it, sketch it with Mockups: one offline HTML file from your own components, checked by a CLI.