draw/framework-extra-bundle
Symfony bundle that integrates draw/* components with configuration under the draw_framework_extra namespace. Some features auto-enable when components are present; others are opt-in to avoid unnecessary load or side effects. Includes Application and OpenAPI integrations.
spatie/symfony-bundle) or a custom wrapper.enableDoctrineSupport) suggest a modular design, which can be replicated in Laravel via service providers and optional configurations.#[OpenApi\Tag]), which are natively supported in Laravel 9+. Backward compatibility with older Laravel versions would require polyfills (e.g., ramsey/uuid for PHP 7.4).FrameworkExtraBundle, EventDispatcher) requires abstraction or replacement. For example:
EventDispatcher with Laravel’s Events system.FrameworkExtraBundle configurations with Laravel’s Route::attributes() or middleware.enableDoctrineSupport flag implies Doctrine integration, which is optional in Laravel (Eloquent is the default). A custom Doctrine-to-Eloquent mapper would be needed for schema generation.KernelEvents::VIEW) in Laravel would require significant refactoring. The VersionListener example highlights this risk.use Sensio\Bundle\FrameworkExtraBundle\Configuration\...) to attributes (#[Route]) may require rewriting annotation parsers (e.g., using phpdocumentor/reflection-docblock).spatie/laravel-openapi or darkaonline/l5-swagger would need to be extended or replaced.draw:open-api:install-sandbox command introduces a runtime dependency on external versions (e.g., v3.52.5), which could complicate CI/CD pipelines.l5-swagger) or API response serialization (like spatie/laravel-fractal)?EventDispatcher with Laravel’s Events)?mpoiriert) active? Are there alternatives (e.g., zircote/swagger-php)?.env or config/) be managed?spatie/laravel-openapi) or build a custom wrapper?#[OpenApi\Tag] → custom #[ApiTag]).Route::attributes() or middleware to replicate FrameworkExtraBundle functionality.EventDispatcher to Laravel’s Events system (e.g., KernelEvents::VIEW → events:view).config/draw.php with .env overrides.darkaonline/l5-swagger or spatie/laravel-openapi.spatie/laravel-fractal or nesbot/carbon for responses.Schema and Serialization annotations could be adapted into Laravel’s OpenApi\Attributes (PHP 8+).EventDispatcher → Laravel Events.FrameworkExtraBundle → Custom middleware/route attributes.draw:open-api:install-sandbox equivalent (e.g., a Composer script or Artisan command)..env-based configuration, Blade templating for docs).l5-swagger).config_cache, route_model_binding).laravel-shift/doctrine-attributes).symfony/console, symfony/event-dispatcher, and symfony/dependency-injection via Composer, but expect friction in event handling.zircote/swagger-php supports v3).config/draw.php.draw:open-api:install-sandbox as a custom Artisan command (e.g., draw:install).symfony/event-dispatcher may break Laravel’s event system.install-sandbox command introduces versioning risks. Consider:
require-dev).spatie/laravel-package-tools.spatie/laravel-config-array to merge YAML into Laravel’s config..env overrides for sensitive settings (e.g., DRAW_OPEN_API_ENABLE_DOCTRINE=true).VersionListener equivalent).Log::debug('OpenAPI event triggered')) to trace execution.#[OpenApi\Tag]) can slow boot time. Optimize with:
route:cache).bootstrap/app.php.spatie/laravel-queueable-scheduled-jobs).meilisearch for API docs).How can I help you explore Laravel packages today?