qandidate/toggle-bundle
Symfony bundle for Qandidate Toggle that brings feature flags into your app. Define toggles in configuration, check them via the toggle manager, and safely enable or disable features per environment or user without redeploying. Useful for gradual rollouts and A/B tests.
Bottom line: this is a Symfony bundle, not a Laravel package. It cannot be installed into a Laravel application as-is, and its ecosystem signals (89 stars, 0 dependents, dormant upstream) mean we would be adopting a small abandoned codebase rather than a maintained dependency. It is only worth pursuing as a design reference plus a small reusable core, not as an installed bundle.
Architecture fit
TreeBuilder, no service tagging.qandidate/toggle library (toggle model, conditions/context, operator). That is genuinely portable to Laravel behind a service provider; the bundle wrapper is not.Integration feasibility
qandidate/toggle core, write a ~150–300 LOC FeatureToggleServiceProvider that binds the operator as a singleton, hydrates toggles from config/features.php, and exposes a facade plus a Blade directive. Reuse the bundle's config schema as our spec so behaviour matches.Technical risk
composer.json constraints before anything else — this is a go/no-go gate.Key questions
composer require succeed without --ignore-platform-reqs?Stack fit
qandidate/toggle core if we want its condition/context model, wrap it in a service provider, and expose Feature::active('flag') plus an @feature Blade directive. Register a singleton operator bound to a config-backed or cache-backed collection.Migration path
if (config(...)), env checks, isActive calls) and classify each as release toggle, experiment, ops/kill-switch, or permission — they have different lifetimes and different removal owners.ToggleResolver interface with a config-file implementation. This decouples us from any vendor choice and makes the next step reversible.Compatibility
ContainerBuilder/Extension API usage, Twig extension signature (pre-namespacing Twig 1/2 classes break on Twig 3), PSR-11 vs container-interop, and whether the transitive qandidate/toggle dependency itself resolves on current PHP.vcs/path repository and an internal maintenance commitment — factor that into the decision now, not after adoption.Sequencing
composer.json, read the DI extension. This single spike resolves most of the open questions.ToggleResolver seam + config implementation in the app; ship with zero behaviour change.Maintenance
Support
Scaling
Failure modes
fail_open vs fail_closed); default to the last known safe value and log loudly.false is indistinguishable from an intentional off state. Fail loudly on unknown-flag lookups in non-production.Ramp-up
How can I help you explore Laravel packages today?