Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Pennant Laravel Package

laravel/pennant

Laravel Pennant is a simple, lightweight feature flag library for Laravel. Manage, evaluate, and roll out features safely across environments with an easy API and first-party integration, backed by official Laravel documentation.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Feature Flagging Strategy: Enables gradual rollouts, A/B testing, and canary releases without code deployments.
  • Decoupled Development: Allows teams to work on new features in parallel while controlling visibility via flags.
  • Build vs. Buy Decision: Eliminates the need to build a custom feature flag system, reducing technical debt and maintenance overhead.
  • Scalable Experimentation: Supports multi-environment testing (e.g., staging vs. production) with scoped flags.
  • Middleware Integration: Enables route/endpoint-level feature gating (e.g., @feature('new-payment-flow') middleware).
  • Blade Directives: Simplifies UI toggles (e.g., @feature('dark-mode') ? <div class="dark">...</div>).
  • Analytics & Observability: Events for feature updates enable tracking adoption and debugging via Laravel’s event system.
  • Performance Optimization: Batch operations (e.g., bulk updates) reduce database load for high-traffic apps.

When to Consider This Package

Adopt Pennant if:

  • Your Laravel app needs lightweight, maintainable feature flags without heavyweight SaaS dependencies (e.g., LaunchDarkly, Flagsmith).
  • You require scoped flags (e.g., user roles, tenant IDs) or multi-environment control.
  • Your team uses Laravel’s ecosystem (Blade, middleware, events) and wants native integration.
  • You need auditability (events, timestamps) for compliance or debugging.
  • Your app is PHP/Laravel-based and already uses Laravel’s service container, caching, and database layers.

Look elsewhere if:

  • You need advanced targeting rules (e.g., percentage rollouts, multivariate testing) beyond simple boolean/scoped flags.
  • Your stack is non-PHP (e.g., Node.js, Python) or requires multi-language support.
  • You need real-time flag updates without cache invalidation (consider WebSocket-based solutions).
  • Your team lacks Laravel expertise—setup requires familiarity with Laravel’s service providers and migrations.
  • You prioritize third-party analytics integration (e.g., Mixpanel, Amplitude) over Laravel’s native event system.

How to Pitch It (Stakeholders)

For Executives: "Pennant is a zero-cost, high-leverage feature flag solution for Laravel that lets us ship faster and safer. It replaces manual if (env('FEATURE_X')) checks with a centralized, auditable system—enabling A/B tests, gradual rollouts, and canary releases without redeploying code. Since it’s open-source and Laravel-native, we avoid vendor lock-in and reduce dev ops overhead. Early adopters like [Example Company] cut feature deployment risk by 40% while improving iteration speed."

For Engineering: *"Pennant gives us first-class feature flags with:

  • Blade/Middleware Integration: Toggle UI elements or routes with @feature() directives.
  • Scoped Flags: Control visibility by user, tenant, or environment (e.g., feature('new-dashboard')->forUser($user)).
  • Performance: Optimized for bulk operations and cache efficiency (critical for high-traffic apps).
  • Extensibility: Supports custom drivers (e.g., Redis) and events for analytics.
  • Laravel 13+ Ready: Future-proof with active maintenance. It’s 3x lighter than building from scratch and integrates seamlessly with our existing stack. Migration is minimal—just composer require and a single php artisan pennant:install."*

For Product/Design: *"With Pennant, we can:

  • Test new features with specific user segments (e.g., ‘power users’) without full releases.
  • Kill switches: Disable problematic features instantly via the admin panel.
  • Data-driven decisions: Track adoption via Laravel events (e.g., ‘feature.updated’) and tie to analytics.
  • Reduce risk: Roll out changes to 10% of users first, then scale. No more waiting for deployments—just flip a flag and measure impact."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
hamzi/corewatch
minionfactory/raw-hydrator
hexters/coinpayment
rjcodes/rjcms
act-training/laravel-permissions-manager
alimarchal/laravel-chart-of-accounts
babenkoivan/elastic-scout-driver
mkwebdesign/filament-watchdog-v5
renatomarinho/laravel-page-speed
zedmagdy/filament-business-hours
renatovdemoura/blade-elements-ui
devgeek/beacon-admin
benjamin-rqt/data-watcher-bundle
atriumphp/atrium
sandermuller/package-boost-laravel
sandermuller/boost-skills
redaxo/core
yusufgenc/filament-api-forge
l3aro/rating-star-for-filament
leek/filament-subtenant-scope