Installation
Get started with ReacUI in your React project within minutes
Requirements
Peer Dependencies
- React 18 or higher
- React DOM 18 or higher
- Tailwind CSS 3.0 or higher
Browser Support
- Chrome 90+
- Firefox 90+
- Safari 15+
- Edge 90+
Installation
Choose your preferred package manager to install ReacUI:
Version Compatibility
Framework Setup
ReacUI works with all popular React frameworks. Select your framework for specific setup instructions:
Tailwind Setup
ReacUI is built with Tailwind CSS. Follow these steps to properly configure your project:
1Install Tailwind CSS
If you haven't already installed Tailwind CSS in your project, you can do so with:
2Initialize Tailwind CSS
Generate the configuration files:
3Configure Tailwind
Update your tailwind.config.js file to include ReacUI components:
4Add Tailwind Directives
Add the Tailwind directives to your CSS:
Theming
ReacUI comes with a built-in theme provider that supports dark mode and custom color themes.
Basic Theme Setup
The ThemeProvider component handles dark/light mode switching and enables custom theme configuration:
Custom Color Theme
You can customize the color scheme by extending your Tailwind config:
Basic Usage
After setting up ReacUI, you can start using the components in your project:
Next Steps
Now that you've set up ReacUI, explore our component library to see all available components and their usage examples.
Troubleshooting
Components are missing styles
This usually happens when Tailwind isn't configured correctly to scan ReacUI components.
Make sure your tailwind.config.js includes the ReacUI package in its content configuration:
content: ["./node_modules/reacui/**/*.{js,jsx}"]Dark mode isn't working
Ensure you've set darkMode to 'class' in your Tailwind config and that you're using the ThemeProvider component correctly.
darkMode: 'class'TypeScript errors
If you're using TypeScript and seeing type errors, make sure you have the types installed:
npm install --save-dev @types/reacuiNeed more help?
If you're still having issues, check out our GitHub Discussions or open an issue.