- Does baks-dev/drom replace Laravel’s native routing or work alongside it?
- baks-dev/drom is designed to augment Laravel’s routing rather than replace it. It follows Symfony’s modular approach, so you’ll need to bridge its routing logic with Laravel’s `Route::prefix()` or middleware wrappers. No native Laravel routing replacement is included in v7.4.5.
- Is baks-dev/drom compatible with Laravel 10.x and PHP 8.4?
- Yes, v7.4.5 explicitly requires PHP 8.4+ and is tested for Laravel 10.x compatibility. However, no Laravel-specific optimizations are documented, so test middleware and service container bindings in your project to confirm stability.
- How do I integrate baks-dev/drom’s middleware with Laravel’s middleware stack?
- Since baks-dev/drom uses Symfony’s middleware system, you’ll need to wrap its handlers in Laravel-compatible middleware or use custom shims. Laravel’s `Middleware` facade or `app()->make()` can bind Symfony middleware to Laravel’s pipeline, but this requires manual setup.
- Can I use Eloquent models with baks-dev/drom for database operations?
- No, baks-dev/drom does not include Eloquent integration. It focuses on API layers and domain-driven routing, so database operations must rely on Laravel’s native Eloquent or Query Builder. Consider alternatives like Spatie’s Laravel packages if Eloquent is a core requirement.
- Are there Laravel-specific Facade wrappers for baks-dev/drom in v7.4.5?
- No Laravel Facade support is documented in v7.4.5. The package remains Symfony-centric, so you’ll need to manually bind its services to Laravel’s container or use dependency injection directly. Check the release notes for any undocumented changes.
- What are the risks of using baks-dev/drom in a production Laravel app?
- The primary risks are Symfony-Laravel integration gaps, such as middleware conflicts or routing inconsistencies. Since v7.4.5 doesn’t resolve these natively, test thoroughly in a staging environment. Monitor logs for dependency clashes, especially if using Laravel’s Service Container alongside Symfony’s DI.
- How do I test baks-dev/drom in a Laravel project?
- Run the package’s tests with `php bin/phpunit --group=drom`, but these may not cover Laravel-specific scenarios. Create custom test cases for middleware, routing, and service container bindings. Use Laravel’s `HttpTests` or `FeatureTests` to validate API endpoints wrapped with baks-dev/drom.
- Does baks-dev/drom support Laravel’s validation rules or forms?
- No, baks-dev/drom does not integrate with Laravel’s validation system. It provides its own validation layer inspired by Symfony’s Validator. If you need Laravel’s validation (e.g., Form Requests), you’ll need to manually map Symfony validation constraints to Laravel’s rules or use a hybrid approach.
- Are there alternatives to baks-dev/drom for Laravel microservices?
- Yes, consider Laravel-specific packages like `laravel-api` (for modular APIs), `spatie/laravel-api` (for RESTful resources), or `fruitcake/laravel-cors` for microservice-friendly CORS. If Symfony integration is critical, evaluate `symfony/http-kernel` directly or `laravel/symfony-components` for partial adoption.
- How do I downgrade from baks-dev/drom v7.4.5 if it causes issues?
- Downgrade via Composer: `composer require baks-dev/drom:7.4.4`. Clear Laravel’s cache (`php artisan cache:clear`) and test middleware/routing bindings. If the issue persists, check the package’s changelog for breaking changes in v7.4.5 and revert custom shims or adapters.