Enables your PHP application to expose its entities as REST resources using the feature rich JSON:API specification as API. How and to whom your entities are exposed is highly customizable while minimizing boilerplate code.
MIT License
2
stars
1
forks
source link
Prefer `non-empty-list` over variable length argument lists #151
Before the commitment on phpstan and its types, signatures like the following were used to ensure that at least one value was provided.
function(string $head, string... $tail)
This has no serious drawbacks, but using the following approach is more simple and conveys the intention better, even though it will not automatically provide a "break hard, break early" behavior:
Before the commitment on phpstan and its types, signatures like the following were used to ensure that at least one value was provided.
This has no serious drawbacks, but using the following approach is more simple and conveys the intention better, even though it will not automatically provide a "break hard, break early" behavior:
The signatures that need to be adjusted are marked with
(#151)
in the source code.