Installation
Get started with uicomponents.dev in minutes
uicomponents.dev takes a different approach to UI libraries. Instead of installing packages, you simply copy and paste components directly into your project. This gives you full control and eliminates dependencies.
Choose your component
Browse our library and find the component you need
Copy the code
Click the copy button to get the component code
Paste into your project
Add the component to your components directory
Install dependencies
Add any required dependencies to your project
React Setup
For React projects, components are written in TypeScript with Tailwind CSS styling.
Note
1. Install Tailwind CSS
-yellow-400">npm install -D tailwindcss postcss autoprefixer
-yellow-400">npx tailwindcss init2. Configure tailwind.config.js
module.exports = {
content: [
"./app/**/*.{js,ts,jsx,tsx,mdx}",
"./components/**/*.{js,ts,jsx,tsx,mdx}",
],
theme: {
extend: {},
},
plugins: [],
}3. Add Tailwind directives to your CSS
@tailwind base;
@tailwind components;
@tailwind utilities;Manual Installation
For components that require additional dependencies, install them manually:
# For components using Lucide icons
-yellow-400">npm install lucide-react
# For form components
-yellow-400">npm install react-hook-form
# For date pickers
-yellow-400">npm install date-fnsRecommended Project Structure
Organize your components in a clear structure:
your-project/
├── app/
│ └── globals.css
├── components/
│ ├── ui/ # Primitive components (Button, Card, etc.)
│ └── feature/ # Feature-specific components
├── lib/
│ └── utils.ts # Utility functions
└── public/Tip
components/ui/ directory for primitive components that you'll reuse across your application.Next Steps
Now that you have everything set up, learn how to use components effectively in your project.