php-fig/log ? reverse-engineered prompt
Reverse engineered prompt
Build me a small PHP package for PSR 3 logging that gives other projects a standard logger contract to depend on.
I want it to be installable with Composer, and the main thing it should provide is the logger interface and the related helper classes or traits a developer would use to implement or type hint against it. It does not need to be a logger itself, just the shared interface layer so apps can accept any logger that follows the PSR 3 style.
Please make it clean, simple, and ready for use in real projects, with a short README example showing how a class can accept an optional logger and write messages like info and error. If there are standard details from the current PSR 3 docs that matter, please use them, and look up the latest docs online if needed.
Are you gonna build this?
make sure you review the code using coderabbit