A collection of behavioral extensions for Doctrine ORM and MongoDB ODM, adding features like translatable content, slugs, trees, and timestamps.
DoctrineExtensions is a PHP library that provides behavioral extensions for Doctrine ORM and MongoDB ODM, adding common functionalities like translatable content, automatic slug generation, tree structure management, and timestamp tracking. It solves the problem of repetitive boilerplate code by automating these tasks through Doctrine's event system, making database interactions more efficient and maintainable.
PHP developers using Doctrine ORM or MongoDB ODM in frameworks like Symfony, Laravel, or Laminas, who need advanced data handling features without writing custom logic for translations, slugs, trees, or auditing.
Developers choose DoctrineExtensions for its comprehensive set of ready-to-use behaviors, seamless integration with Doctrine's event system, and support for multiple mapping strategies (attributes, XML, annotations). It reduces development time, ensures consistency, and is maintained with modern PHP and Doctrine versions.
Doctrine2 behavioral extensions, Translatable, Sluggable, Tree-NestedSet, Timestampable, Loggable, Sortable
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Offers a wide range of ready-to-use extensions like Translatable, Sluggable, and Tree, drastically reducing boilerplate code for common database operations as listed in the README.
Provides dedicated documentation for Symfony, Laravel, and Laminas, making setup straightforward in popular PHP ecosystems without major configuration hassles.
Version 3.0 bumps requirements to latest PHP and Doctrine versions, ensuring compatibility with current development standards and long-term maintainability.
Supports attributes, XML, and annotations for entity mapping, allowing developers to choose their preferred method based on project needs and modern practices.
Configuring the Entity Manager without a framework requires manual tweaks to avoid issues, as noted in the example/em.php file, which can be error-prone for inexperienced users.
Documentation is split into separate markdown files per extension, making it harder to get a consolidated overview and increasing the learning curve for new adopters.
The event-driven architecture can add latency in high-traffic applications, especially with extensions like Loggable that increase database writes during flush operations.
Some extensions are ORM-only (e.g., SoftDeleteable) or have restricted strategies in MongoDB ODM (e.g., Tree only supports materialized path), reducing flexibility in mixed database environments.