PE

pennant-development

Integrates Laravel Pennant for managing feature flags and gradual rollouts.

Install

mkdir -p .claude/skills/pennant-development && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/2322" && unzip -o skill.zip -d .claude/skills/pennant-development && rm skill.zip

Installs to .claude/skills/pennant-development

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Use when working with Laravel Pennant the official Laravel feature flag package. Trigger whenever the query mentions Pennant by name or involves feature flags or feature toggles in a Laravel project. Tasks include defining feature flags checking whether features are active creating class based features in `app/Features` using Blade `@feature` directives scoping flags to users or teams building custom Pennant storage drivers protecting routes with feature flags testing feature flags with Pest or PHPUnit and implementing A B testing or gradual rollouts with feature flags. Do not trigger for generic Laravel configuration authorization policies authentication or non Pennant feature management systems.
706 chars✓ has a “when” triggerlonger than Claude Code's old 250-char listing cap (fine on current versions)
Intermediate

Key capabilities

  • Define feature flags with class-based logic
  • Implement Blade directives for conditional UI
  • Apply scoped feature rollouts by user or team
  • Build custom storage drivers for feature flags

How it works

Uses a provider-based registry to store and evaluate feature state for specific entities defined in the application.

Inputs & outputs

You give it
Feature name, scope/user, and toggle state
You get back
Boolean status of feature availability

When to use pennant-development

  • Define new feature flags
  • Implement A/B testing
  • Toggle feature availability
  • Protect routes with features

About this skill

Pennant Features

Documentation

Use search-docs for detailed Pennant patterns and documentation.

Basic Usage

Defining Features

<!-- Defining Features -->
use Laravel\Pennant\Feature;

Feature::define('new-dashboard', function (User $user) {
    return $user->isAdmin();
});

Checking Features

<!-- Checking Features -->
if (Feature::active('new-dashboard')) {
    // Feature is active
}

// With scope
if (Feature::for($user)->active('new-dashboard')) {
    // Feature is active for this user
}

Blade Directive

<!-- Blade Directive -->
@feature('new-dashboard')
    <x-new-dashboard />
@else
    <x-old-dashboard />
@endfeature

Activating / Deactivating

<!-- Activating Features -->
Feature::activate('new-dashboard');
Feature::for($user)->activate('new-dashboard');

Verification

  1. Check feature flag is defined
  2. Test with different scopes/users

Common Pitfalls

  • Forgetting to scope features for specific users/entities
  • Not following existing naming conventions

When not to use it

  • Complex authorization policies
  • Non-Laravel projects
  • Standard authentication handling

Prerequisites

Laravel frameworkLaravel Pennant package

Limitations

  • Requires explicit scoping logic
  • Naming conventions must be strictly maintained
  • Dependent on Laravel's service container

How it compares

It moves feature toggling from hard-coded conditionals to a managed, scoped service layer.

Compared to similar skills

pennant-development side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
pennant-development (this skill)24moNo flagsIntermediate
extending-shopper14moNo flagsIntermediate
controller16moNo flagsBeginner
filament-5-resources03moNo flagsIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

Search skills

Search the agent skills registry