DocsInstallation
Built by DesignMe, free to use under the MIT licence.
Expert design and dev support for startups and enterprises.
Book a callInstallation
Add components with the designme CLI. It copies their source into your project, so you own it.
Before you start
Node 18 or later
To run the CLI.
React 19
For the React components.
Find a component's install name on its page, or list them all:
npx designme listAdd components
Add them
Terminalnpx designme add status-pill thinking composerEach component lands in its own folder in
./designme, with its.html,.cssand.js. The shared core,core/core.cssandcore/core.js, is added once. Every component also gets ademo.htmlyou can open straight away.Your project - designme/
- core/
- core.css
- core.js
- status-pill/
- status-pill.html
- status-pill.css
- status-pill.js
- demo.html
- thinking/
- thinking.html
- thinking.css
- thinking.js
- demo.html
- composer/
- composer.html
- composer.css
- composer.js
- demo.html
- core/
- designme/
Load them in a page
Load the core and the component's files, and copy in the markup from its
.html:HTML<link rel="stylesheet" href="designme/core/core.css"> <link rel="stylesheet" href="designme/status-pill/status-pill.css"> <!-- the markup from designme/status-pill/status-pill.html --> <script src="designme/core/core.js"></script> <script src="designme/status-pill/status-pill.js"></script>Give them your data
The core renders each component when it scrolls into view and plays its demo. To feed one your own data, change its
.js, or use the React version, which takes props.
Add them
Terminalnpx designme add status-pill thinking composer --reactThey land in
src/components/designme, orcomponents/designmewhen there is nosrcfolder. Only the shared files they need come with them:designme.cssand a few helpers inlib/.Your project - src/components/designme/
- designme.css
- lib/
- cx.ts
- hits.ts
- hooks.ts
- icons.tsx
- motion.tsx
- popover.tsx
- status-pill/
- StatusPill.tsx
- status-pill.css
- thinking/
- Thinking.tsx
- thinking.css
- composer/
- Composer.tsx
- composer.css
- src/components/designme/
Import them
Each component imports its own styles, so importing it is all it takes:
Reactimport { StatusPill } from '@/components/designme/status-pill/StatusPill'; <StatusPill state="reading" label="Reading Figma frames" meta="2 of 4" />Drive them from your state
Every component takes
className. Anything a person can change has a controlled pair, likevalueandonValueChange, and adefault…prop for leaving it to the component. Each component's page lists its props.Load Inter and JetBrains Mono for the full look. Without them, the components fall back to the system font.
Every class, CSS variable and animation name starts with dm-, so the components sit beside Tailwind, shadcn/ui or your own CSS without clashing.
Frameworks
Next.js
App Router: every component file starts with
'use client', so you can render them from server components.Pages Router: import
designme.cssand each component's.cssinpages/_app.tsx, and delete the two CSS imports at the top of those components.React with Vite
Nothing extra to set up.
Astro
Add the React integration with
npx astro add react. Hydrate the components that change over time, for example withclient:visible.
Options
| Option | What it does |
|---|---|
--react | React components instead of HTML, CSS and JavaScript |
--examples | With --react, an example beside each component that replays its demo from designme.dev |
--dir <path> | Put the files somewhere else |
--force | Replace files you already have |
The CLI downloads each component from designme.dev and skips files that are already there. --force replaces them with the current version, including any changes you made.
This page as Markdown: installation.md