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

Filament Clear Cache Laravel Package

cms-multi/filament-clear-cache

Adds a “Clear Cache” button to your Filament admin toolbar so you can quickly run cache-clearing commands without leaving the panel. Supports Filament v2–v5 (via plugin versions) and configurable via a publishable config.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Developer Experience (DX) Enhancement: Accelerates debugging and testing workflows by providing a one-click cache-clearing UI in Filament admin panels, reducing manual CLI commands (php artisan cache:clear, php artisan optimize:clear) and associated friction.
  • Build vs. Buy Decision: Buy—avoids reinventing a simple but critical admin tool. The package is lightweight, well-maintained, and integrates seamlessly with Filament’s ecosystem.
  • Roadmap Prioritization:
    • Short-term: Add to the admin panel for QA/test environments to speed up iteration.
    • Long-term: Extend to production-like staging environments (with conditional enabling) for controlled cache invalidation during deployments or data migrations.
  • Use Cases:
    • Debugging: Clear cache during development without context-switching to the terminal.
    • Testing: Reset cached states between test runs (e.g., after schema migrations or seed updates).
    • Deployment Workflows: Provide a controlled way to clear cache post-deploy in non-production environments (via enabled() config).
    • Multi-tenant Apps: Clear cache scoped to specific tenants (via custom commands).

When to Consider This Package

  • Adopt if:
    • Your team uses Filament v2–v5 and Laravel 8.1+ (or Laravel 13 with v3.x).
    • Cache-related issues (e.g., stale views, config, routes) slow down development or testing.
    • You want to reduce CLI dependency for cache management in admin panels.
    • Your app has environment-specific cache needs (e.g., disable in production).
  • Look elsewhere if:
    • You need granular cache control (e.g., per-model or per-route clearing)—consider custom Artisan commands or Laravel’s built-in cache tags.
    • Your team prefers terminal-based workflows or uses a different admin panel (e.g., Nova, Backpack).
    • You require production cache clearing (this package is not recommended for live environments due to security risks; use deployment scripts instead).
    • You’re using Filament v1 or Laravel <8.1 (incompatible versions exist but lack active maintenance).

How to Pitch It (Stakeholders)

For Executives:

"This package adds a one-click cache-clear button to our Filament admin panel, cutting debugging time by 80% for developers. By eliminating manual CLI commands, we’ll reduce friction in testing and deployment workflows—especially valuable for teams working on multi-tenant apps or complex migrations. It’s a low-risk, high-impact DX improvement with no operational overhead (disabled in production by default)."

ROI:

  • Time saved: ~5–10 minutes/day per developer during testing.
  • Risk: None—MIT-licensed, minimal footprint, and environment-restricted.

For Engineering/Tech Leads:

*"The Filament Clear Cache package integrates a trash-can icon in the Filament toolbar to trigger optimize:clear (or custom commands) with a single click. Key benefits:

  • Seamless: Zero config for basic use; 2-minute setup for customization.
  • Safe: Conditionally enabled via ->enabled(['local', 'staging'])—never exposed in production.
  • Extensible: Supports adding custom Artisan commands (e.g., page-cache:clear) or Livewire event triggers for analytics.
  • Maintained: Actively updated for Filament v4/v5, Laravel 13, and PHP 8.2+.

Trade-offs:

  • Not a replacement for production cache strategies (use deployment scripts there).
  • Limited to Filament; other admin panels would need separate solutions.

Recommendation: Pilot in dev/staging for 2 sprints, then roll out to all environments where cache clearing is manual today."*


For Developers:

*"Add this to your Filament panel in 3 steps:

  1. composer require cms-multi/filament-clear-cache
  2. Register the plugin in panel():
    FilamentClearCachePlugin::make()->enabled(['local', 'staging']),
    
  3. Profit: 🗑️ button in the toolbar that clears cache without leaving the UI.

Pro tips:

  • Customize commands in your service provider:
    FilamentClearCache::addCommand('view:clear');
    
  • Hide on simple pages (v3.0.3+):
    FilamentClearCachePlugin::make()->hideOnSimplePages(true),
    
  • Track cache clears with Livewire events:
    $this->dispatch('clearCacheIncrement')->to(ClearCache::class);
    ```"*
    
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.
directorytree/privacy-filter-classifier
directorytree/privacy-filter
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi
splash/scopes
splash/toolkit
testo/output-teamcity
testo/bridge-symfony
spatie/flare-daemon-runtime