Engineering,
taught
&
leadership,
practised.
I'm Steven — CTO at Digitonic, a PHP engineer since 2010 and a keen golfer with a terrible handicap. This is where I write it all down.
Latest from the journal
fopen() Returned false. Why? PHP 8.6's Stream Error API
PHP 8.6 finally gives streams a structured error model. Here's how to move a Laravel file helper off @fopen() and error_get_last() onto StreamException.
Ask Jev Thirteen Questions at Once: Batching and Speculative Fan-Out in Laravel
Thirteen Jev questions in one request cost roughly what one question costs, because the state is only sent once. Here's the Laravel QuestionSet that makes adding a question a one-line change.
PHP 8.6's clamp(): Delete Your min(max()) Sandwiches
Every Laravel codebase has a min(max($perPage, 1), 100) somewhere, and at least one of them has the bounds backwards. PHP 8.6 gives you a function that can't be written wrong.