agence-adeliom/easy-common-bundle
Symfony bundle providing common utilities for EasyAdmin: reusable Doctrine entity traits (ID, slug, timestamps, soft delete, publish/status) and a PHP 8 enum polyfill/helper with static constructors, validation, and typed enum parameters.
ID, slug, publishable) via reusable traits, improving maintainability for teams managing multiple admin interfaces.ThreeStateStatusTrait for complex workflows like "draft/published/archived").Look Here If:
Look Elsewhere If:
"This package cuts the time to build admin panels by 30–50% by providing reusable ‘building blocks’ for common database patterns—like timestamps, status fields, or soft deletes—without sacrificing flexibility. For example, instead of writing 50 lines of code to add a ‘published_at’ field and logic to every entity, we can use a single trait. This aligns with our goal to [reduce tech debt/accelerate feature delivery] while keeping our Symfony/EasyAdmin stack modern. The MIT license and active maintenance (Symfony 6/7 support) make it a low-risk choice."
*"Problem: EasyAdmin is great for CRUD, but we’re wasting time rewriting the same entity logic (e.g., slug generation, soft deletes) across projects. Solution: This bundle gives us batteries-included traits for:
ID, name, slug, timestamps.use the trait), but we cede control over edge cases (e.g., slug collision handling).*
Alternatives: Building custom traits or using Spatie’s packages—but this is EasyAdmin-specific and lighter weight."**"Why This?
SoftDeletable entity? One trait. Need a publishable flag? Done.enum-like syntax without upgrading PHP.
How to Adopt:composer require agence-adeliom/easy-common-bundle.use EntityTimestampableTrait).->setFormOptions(['disabled' => ['deletedAt']]) for soft deletes).
Caveats:EntityNameSlugTrait auto-generates slugs from name—customize if needed.// Before: 20+ lines of code for timestamps + soft deletes
// After:
use App\Entity\Traits\EntityTimestampableTrait;
use App\Entity\Traits\EntitySoftDeletableTrait;
class Article
{
use EntityTimestampableTrait;
use EntitySoftDeletableTrait;
// ...
}
```*
**Docs**: [GitHub](https://github.com/agence-adeliom/easy-common-bundle) (lightweight; check `src/Traits/` for usage).*
How can I help you explore Laravel packages today?