CLI
The CLI isn’t the only way to install Intent, but it’s by far the most convenient. It’s built to make setting up your project fast and hassle-free.
Command Line Interface (CLI)
The CLI is designed to help you set up your project with Intent quickly and efficiently. It’s the easiest and most convenient way to install Intent, allowing you to get started with your project in just minutes.
Existing Project
If you already have a project set up—whether it’s built with Laravel, Next.js, Remix, Tanstack, or any other framework—simply run the following command to install Intent:
This command will prompt you to confirm your project’s setup. However, the CLI is smart enough to detect your project type and provide default values.
Start a New Project
The CLI is highly flexible and can automatically detect whether you already have a project set up. If you don’t, you can start fresh by running the init
command like this:
Add
Once you’ve set up Intent, you can start adding components easily by running the add
command:
This will display the components that differ from your installed versions and provide a list so you can quickly choose which components to update.
Alias
If you’re tired of typing npx @intentui/cli@beta
, you can create an alias for the CLI by adding the following line to your .bashrc
or .zshrc
file:
Then you can run the CLI using the intentui
command:
Shadcn CLI
You might notice that we provide our own CLI, but if you prefer using the ShadCN CLI, that's totally fine. To get started, initialize your application with the following command:
It currently offers 5 starter styles, including blue
, indigo
, emerald
, and sky
, so you can replace default
with any style you prefer.
Once initialized, you can add components by running:
Let’s say you want to add a card component. Just replace <component>
with card
, like this: