Requirements
Before installing Hux UI, ensure your development environment meets these requirements:Flutter SDK
Flutter SDK
Flutter 3.16.0 or higher
Dart SDK
Dart SDK
Dart 3.0.0 or higher (included with Flutter)
Platform Support
Platform Support
- Android (API level 21+)
- iOS (iOS 12.0+)
- Web (JS and WASM)
- Windows (Windows 10+)
- macOS (macOS 10.15+)
- Linux (Ubuntu 18.04+)
Installation
Method 1: Using Flutter Command Line
Add Hux UI to your Flutter project using the command line:pubspec.yaml
file and run flutter pub get
.
Method 2: Manual Installation
Alternatively, you can manually add Hux UI to yourpubspec.yaml
file:
pubspec.yaml
Import and Setup
1. Import Hux UI
Import Hux UI in your Dart files where you want to use the components:2. Configure Themes
Wrap yourMaterialApp
with Hux UI themes for the best experience:
main.dart
3. Start Using Components
You’re now ready to use Hux UI components in your app:Verification
To verify that Hux UI is properly installed and working:1. Check Dependencies
Ensure these dependencies are listed in yourpubspec.yaml
:
2. Test Import
Create a simple test to verify the import:test.dart
3. Run Your App
Start your Flutter app:Troubleshooting
Dependency Conflicts
Dependency Conflicts
If you encounter dependency conflicts, try:Check for version conflicts with other packages in your
pubspec.yaml
.Import Errors
Import Errors
If you get import errors:
- Ensure you’re using the correct import:
import 'package:hux/hux.dart';
- Check that the package is listed in your
pubspec.yaml
- Run
flutter pub get
to fetch dependencies - Restart your IDE/editor
Theme Issues
Theme Issues
If themes aren’t working correctly:
- Ensure you’re using
HuxTheme.lightTheme
andHuxTheme.darkTheme
- Check that
MaterialApp
is properly configured - Verify theme mode settings
- Make sure components are wrapped in a
MaterialApp
context
Platform Specific Issues
Platform Specific Issues
For web applications, ensure you have the latest Flutter web support:For desktop platforms:
Next Steps
Now that Hux UI is installed, you can:Follow the Quickstart
Learn the basics with our quickstart guide
Explore Components
Discover all available UI components
Learn Theming
Customize themes and design tokens
View Examples
See practical implementation examples
Package Information
- Latest Version: 0.2.1
- Package URL: pub.dev/packages/hux
- Repository: github.com/zoeglbrt/hux
- License: MIT
- Author: Zoe Gilbert