Overview for 'tomasvotruba'
Written by Tomáš Votruba
/ Original link
on Jan. 18, 2021
Are you new to Symplify? In short, it's a set of packages I wrote that focuses on improving daily PHP development. It brings joy to the code, so you can focus more on what you love. Are you a Symplify power user? You still might find some new tricks you didn't know about.
Written by Tomáš Votruba
/ Original link
on Jan. 11, 2021
Duplicated code is a code smell that hides the potential of better design. How can we find it? Is it 100 % identical code token by token? Are methods getName() and getName() on 2 entities duplicated? Today we look at PHPStan and how to use it to find duplicated class methods.
Written by Tomáš Votruba
/ Original link
on Jan. 4, 2021
I'm trying to write code that is independent of abstract classes. Type-juggling can create n-matrix complexity in both directions and remind me of stringy static code where everything is one type - mixed. But we cannot always avoid it. Do you use repositories with one abstract repository? Projects…
Written by Tomáš Votruba
/ Original link
on Dec. 28, 2020
Why do you use coding standards? To standardize the design of your code so that any contributor will produce somewhat similar PHP code. Where do we use it? In CI pipelines on every pull-request, locally in a command line or within PHPStorm. Now take these 3 places and drop coding standard from them.
Written by Tomáš Votruba
/ Original link
on Dec. 21, 2020
Conjunction of 2 releases came in December 2020, Symfony 5.2 and PHP 8.0. I wanted to give them a fresh try, so I've updated composer.json in 3 projects, run the Rector upgrade set, and this happened...
Written by Tomáš Votruba
/ Original link
on Dec. 14, 2020
In Symplify 8, a bunch of PHP rules was part of the symplify/coding-standard package. It was a mix of too many tools, so we decided to decouple a new package - symplify/phpstan-rules. During summer 2020, our Rector team grew from 1 member to 4. To keep onboarding smooth, we started to use PHPStan…