Installation
Get started with Chromia UI by adding it to your Flutter project. This guide will walk you through the installation process and verify your setup.Prerequisites
Before installing Chromia UI, ensure your environment meets the following requirements:- Dart:
>=3.10.0 <4.0.0 - Flutter:
>=3.38.0
Add Chromia UI to Your Project
Add the dependency
Open your project’s
pubspec.yaml file and add chromia_ui to your dependencies:pubspec.yaml
Always use the latest version available on pub.dev.
Install the package
Run the following command in your terminal to install the package:This will download Chromia UI and all its dependencies to your project.
Verify Installation
To verify that Chromia UI has been installed correctly, create a simple test widget:main.dart
Complete Configuration
For a production-ready setup, you’ll want to properly configure the theme system. Here’s a more complete example:main.dart
Additional Dependencies
Chromia UI includes the following dependencies automatically:flutter_syntax_view: ^4.1.7- For code syntax highlightingintl: ^0.20.2- For internationalization support
Troubleshooting
Package not found error
Package not found error
If you see a “package not found” error, ensure:
- Your
pubspec.yamlsyntax is correct (proper indentation) - You’ve run
flutter pub getafter adding the dependency - Your internet connection is stable
- You’re using a compatible Flutter version (
>=3.38.0)
Version conflict errors
Version conflict errors
If you encounter version conflicts:
- Check that your Flutter SDK version meets the minimum requirement
- Run
flutter pub upgradeto update compatible dependencies - Review the error message for specific conflicting packages
Import errors
Import errors
If imports aren’t resolving:
- Ensure you’ve run
flutter pub get - Restart your IDE or run
flutter cleanfollowed byflutter pub get - Check that the import path is correct:
package:chromia_ui/chromia_ui.dart
Next Steps
Now that you have Chromia UI installed, you’re ready to start building:Quick Start Guide
Build your first app with Chromia UI components
Theme Configuration
Learn how to customize themes and colors
Components Overview
Explore all available components
Design Tokens
Understand the design token system
