Closed dkraczkowski closed 6 years ago
@smalot I have used to do this but to be honest couple years ago I have changed my mind if comes to suffixes around traits and interfaces from the following reasons:
Interface
they code against contract and follow good practices.Class
and functions with Function
prefixes?I am happy to discuss this further ;)
Just to be clear, I do understand why standards are there for and why I should use them. I am always trying to follow standards I like consistency, I like rules (they make life easier and world maintainable). If I would create a psr package I would for sure go for all the rules that are recommended by PSR group. On the other hand being a creator is also being a critic- as developers we should criticise the world around us to make it better a place. I hope this short explanation makes sense to you :)
Sounds good for me, no problem ;) In all cases, your code is very smart !
I love your integration of:
Keep going !
Thanks :)
I have one remark on your code. When creating interface, I usually add
Interface
as a suffix.This avoids any mistake when using "Route" object which can be an interface or a class, depending only the namespace.
A great documentation: https://www.php-fig.org/bylaws/psr-naming-conventions/