-
-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Welcome to the Laravel FeatureBox Wiki! This comprehensive guide will help you understand, install, and use the Laravel FeatureBox package effectively.
Laravel FeatureBox is a simple, flexible feature toggle system for Laravel applications. It allows you to control feature visibility across different environments, users, and conditions.
composer require mohamedhekal/laravel-featurebox
php artisan vendor:publish --tag=featurebox-config
php artisan vendor:publish --tag=featurebox-migrations
php artisan migrateuse FeatureBox\Facades\FeatureBox;
// Enable a feature
FeatureBox::enable('new_feature');
// Check if feature is enabled
if (FeatureBox::isEnabled('new_feature')) {
// Feature is active
}Complete step-by-step installation instructions, including requirements, configuration, and troubleshooting.
Comprehensive documentation of all available methods and their usage.
Detailed guide on how to use different types of conditions for feature control.
Reference for all available command-line tools and their options.
Complete configuration options and environment variables.
Real-world examples and use cases for different scenarios.
Advanced patterns and techniques for complex feature management.
Common issues and their solutions.
Performance optimization tips and best practices.
Security considerations and best practices.
- Simple & Lightweight: Easy to install and use
- Flexible Conditions: Support for environments, user roles, dates, and custom conditions
- High Performance: Built-in caching support
- Artisan Commands: Manage features from the command line
- Secure: No external API calls, all logic is local
- Database Storage: Features stored in your database
- Testable: Comprehensive test suite included
- Multi-language: Documentation in English and Arabic
- PHP >= 8.1
- Laravel >= 10.0
- MySQL/PostgreSQL/SQLite
laravel-featurebox/
├── src/
│ ├── FeatureBox.php # Main feature logic
│ ├── FeatureBoxServiceProvider.php
│ ├── Contracts/
│ │ └── FeatureBoxInterface.php
│ ├── Facades/
│ │ └── FeatureBox.php
│ └── Commands/
│ ├── EnableFeatureCommand.php
│ ├── DisableFeatureCommand.php
│ └── ListFeaturesCommand.php
├── config/
│ └── featurebox.php
├── database/
│ └── migrations/
├── tests/
└── docs/
- Install the package (see Installation Guide)
- Configure the package (see Configuration)
- Enable your first feature (see Examples)
- Learn advanced usage (see Advanced Usage)
We welcome contributions! Please see our Contributing Guide for details.
- GitHub Issues: Report bugs
- GitHub Discussions: Ask questions
- Email: [email protected]
This package is open-sourced under the MIT license.
Developed by Mohamed Hekal