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 Versionable Laravel Package

visualbuilder/filament-versionable

Filament plugin to manage Eloquent model revisions with polymorphic user support. View diffs, see who changed what, browse revision history, and restore any previous state. Built on visualbuilder/versionable for multi-user-model tracking.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Compliance & Auditability: Enable versioning for critical models (e.g., content, configurations, or financial records) to track changes, who made them, and when—aligning with regulatory requirements (e.g., GDPR, SOX).
  • Content Collaboration: Support multi-role user systems (e.g., Admin, Editor, Contributor) by leveraging polymorphic user relationships, reducing friction in collaborative workflows (e.g., CMS, documentation platforms).
  • Disaster Recovery: Provide a restore mechanism for accidental data corruption or unauthorized edits, reducing downtime and manual recovery efforts.
  • Roadmap Prioritization:
    • Build vs. Buy: Avoid reinventing versioning wheels; adopt this package to accelerate feature delivery (e.g., "Add audit trails to all resources" in 2 sprints vs. 6+).
    • Phased Rollout: Start with high-risk models (e.g., pricing tables, legal documents) before expanding to low-risk ones (e.g., blog posts).
  • Use Cases:
    • Internal Tools: Track changes to admin dashboards, user permissions, or API configurations.
    • Customer-Facing Apps: Version control for user-generated content (e.g., profiles, reviews) with granular permissions.
    • Legacy Migration: Retrofit versioning to existing Filament apps without major refactoring.

When to Consider This Package

  • Adopt If:

    • Your app uses Filament 4.x/5.x and Laravel 10/11/12 with PHP 8.2+.
    • You need polymorphic user support (e.g., multiple user models like Admin, Customer).
    • Your team prioritizes low-code integration over custom solutions (e.g., no need to build diff engines or UI from scratch).
    • You require visual diffs, restore actions, and revision history out-of-the-box.
    • Your models have moderate-to-high edit frequency (e.g., content-heavy apps) but not extreme scale (e.g., millions of versions).
  • Look Elsewhere If:

    • You’re on Filament 3.x or unsupported Laravel/PHP versions (requires custom fork).
    • You need fine-grained versioning (e.g., per-field timestamps) beyond snapshot/diff strategies.
    • Your app demands high-performance versioning (e.g., real-time sync for 100K+ versions); consider specialized packages like spatie/laravel-activitylog with custom optimizations.
    • You require offline/air-gapped versioning (this package relies on database migrations).
    • Your team lacks Filament familiarity (steep learning curve for customization).

How to Pitch It (Stakeholders)

For Executives:

"This package lets us add audit trails and undo functionality to critical data—like a ‘Ctrl+Z’ for our admin tools—without building it from scratch. For example, if a marketer accidentally publishes a broken campaign, we can instantly restore the previous version. It also supports multiple user types (e.g., admins vs. editors), which is key for our [Product X] collaboration features. The cost? A few hours of setup vs. months of dev time. ROI: Reduced errors, faster compliance, and happier users."

Key Metrics to Track:

  • % of high-risk models with versioning enabled (e.g., 80% of content/resources).
  • Time saved on manual data recovery (e.g., "Saved 10 hours/month on rollbacks").
  • Compliance audit pass rates (e.g., "100% of GDPR data change logs now automated").

For Engineering:

*"This is a drop-in Filament plugin that adds versioning to Eloquent models with:

  • Polymorphic users: Works with any user model (e.g., Admin, Customer).
  • Visual diffs: See exactly what changed in a Filament UI (no manual SQL queries).
  • Restore actions: One-click rollback to any previous state.
  • Minimal setup: Just add a trait to your model and configure Filament resources.

Trade-offs:

  • Pros: Faster than custom solutions, tested, and Filament-native.
  • Cons: Limited to Filament 4/5; snapshot strategy may bloat storage for large models (use DIFF strategy cautiously).

Recommendation: Pilot with 2–3 high-impact resources (e.g., Product, UserProfile) before full rollout. Pair with database indexing for versions table if performance is critical."*

Tech Deep Dive:

  • Under the Hood: Built on visualbuilder/versionable, which extends overtrue/laravel-versionable with Filament UI.
  • Customization Hooks:
    • Override shouldStripTags() for HTML content.
    • Publish views to modify the revision UI.
    • Extend RevisionsPage for custom logic (e.g., filtering by user role).
  • Performance: Test with your largest model first—snapshot strategy stores full copies of $versionable attributes.
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.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky