Description
sugarcube is a tool for building front ends on DTCG design tokens. It connects your tokens to CSS variables, utility classes and CUBE CSS, and it can generate copy-to-own components. You use it through a Vite plugin or through the command line interface. The quick start walks you through the setup, which includes starter tokens, CUBE CSS, components and the Vite plugin. The CLI is installed locally, so after setup you can run sugarcube directly, or add it to your npm scripts. The project is split into three packages. @sugarcube-sh/cli handles initialization, generation and components. @sugarcube-sh/vite is a Vite plugin with hot module replacement, and @sugarcube-sh/core does the token processing. Documentation is at sugarcube.sh/docs, and the repository includes a LICENSE.md file. The tagline is that design tokens go in and CSS and components come out. It is aimed at front-end developers who keep their design tokens in the DTCG format and want them turned into styles.…
Highlights
- Turns DTCG design tokens into CSS
- CSS variables, utility classes and CUBE CSS
- Copy-to-own components
- Vite plugin with hot module replacement
- CLI for setup and generation
Ratings & Reviews
No ratings yet
Be the first to rate @sugarcube-sh/cli.
People also visit
@sugarcube-sh/cli FAQ
What is sugarcube?
A tool that builds front ends on DTCG design tokens, turning them into CSS variables, utility classes and components.
How do I start?
Follow the quick start, which sets up starter tokens, CUBE CSS, components and the Vite plugin.
Do I need Vite?
No. The README shows a setup with the Vite plugin and one without it, using the CLI.
What packages does it include?
@sugarcube-sh/cli for setup and generation, @sugarcube-sh/vite for the Vite plugin, and @sugarcube-sh/core for token processing.
Where are the docs?
At sugarcube.sh/docs.
What are the best @sugarcube-sh/cli alternatives?
Popular alternatives to @sugarcube-sh/cli include @unpunnyfuns/swatchbook-blocks, tokenui and skillui. See all @sugarcube-sh/cli alternatives













