atournayre/framework

A framework and helpers on top of Symfony

0.0.1 2024-10-18 13:15 UTC

This package is auto-updated.

Last update: 2024-11-18 13:35:10 UTC


README

Warning: This documentation is a work in progress.

Currently, it is compatible with PHP 7.4 ans Symfony 5.4.

Documentation

This is the documentation for the project.

Architecture Decision Records

Architecture Decision Records (ADRs) are a way to document the architectural decisions made during the development of the project. List of ADRs can be found here.

Primitives

Primitives are the basic building blocks of the project. They are the smallest units of the project that can be used to build more complex structures. List of primitives can be found here.

Handling nullable values using the Null Object Pattern

In this project, we use the Null Object Pattern to handle nullable values. You can read more about it here.

DateTimeInterface

Use the Atournayre\Contracts\DateTimeInterface instead of the \DateTimeInterface class to represent dates and times.

Logging

Use the Atournayre\Contracts\LoggerInterface to log messages in the project.

Collections

Usage or arrays is discouraged in the project. Use Collections instead. You can read more about it here.

HTTP/Session/Templating

Use the Atournayre\Contracts\HttpInterface, Atournayre\Contracts\SessionInterface, and Atournayre\Contracts\TemplatingInterface to interact with the HTTP protocol, manage sessions, and render templates.

Filesystem

Use the Atournayre\Contracts\FilesystemInterface to interact with the filesystem.

Events

Add the HasEventsInterface to an object to allow it to dispatch events and add the EventsTrait to add events to an object. Implement missing methods from the HasEventsInterface in the object.