spartan
Installation
SKILL.md
spartan/ui
spartan/ui is an Angular UI library. It uses a two-layer architecture:
- Brain (
@spartan-ng/brain) - accessible, unstyled primitives (Angular directives/components), installed from npm. This is the behavior and accessibility layer. - Helm (
@spartan-ng/helm) - the styled layer (Tailwind + class-variance-authority). Helm code is copied into the user's project by the CLI so they own and can customize it.
You compose Helm directives/components onto host elements; Helm wires up the matching Brain primitive under the hood. Always prefer existing components over hand-written markup.
All CLI commands run through the workspace's runner. Detect it from the project:
- Nx workspace (has
nx.json):npx nx g @spartan-ng/cli:<generator>(orpnpm nx g ...). - Angular CLI workspace (has
angular.json, nonx.json):ng g @spartan-ng/cli:<generator>.