Page 20 - Monthly Archives: January 2025
-
Maxim Mironjuk
-
January 06, 2025
Until PHP 8.0, every default value had to be a constant expression, a new object instance as a default simply was not allowed. Since PHP 8.1, new can stand directly in initializers, in parameters, attribute arguments, and property declarations, making a whole catalog of workarounds unnecessary.
-
Maxim Mironjuk
-
January 06, 2025
Solving Docker performance problems starts with understanding why the three platforms have fundamentally different architectures. On Linux, Docker runs natively; on macOS and WSL2, it runs through a virtualization layer, with measurable consequences for builds, bind mounts, and I/O-heavy applications.
-
Maxim Mironjuk
-
January 06, 2025
A correctly configured PhpStorm environment for Magento 2 saves hours every day: a Docker interpreter for precise code completion, Xdebug without manual steps, CLI runners for Magento commands right inside the IDE, and file templates that create new ViewModels, plugins and repositories in seconds.
-
Maxim Mironjuk
-
January 06, 2025
docker system prune only cleans up locally; the growth of a self-hosted Docker registry with thousands of pushed images is completely unaffected by it. Registry-side garbage collection and thoughtful retention policies are the actual lever against runaway storage consumption.
-
Maxim Mironjuk
-
January 06, 2025
A separate document describing a test suite's purpose and structure feels helpful the moment it's written, but in practice almost inevitably goes stale within a few months, once the described test code keeps evolving while the document itself stays frozen. The most effective form of test documentation is therefore not a separate, independently maintained document, but the test code itself, provided it's written so it reveals its own intent without any additional explanation.
-
Maxim Mironjuk
-
January 06, 2025
Express ships with only weakly typed request and response objects out of the box. With generic types for body, params and query, typed middleware chains and a clear error class hierarchy, a fragile JavaScript framework becomes a TypeScript backend architecture that reports errors at compile time instead of at runtime.
-
Maxim Mironjuk
-
January 06, 2025
Static tests in Magento 2 catch exactly the class of problems that neither PHPStan nor PHPUnit see: violations of the Magento Coding Standard, undeclared dependencies between modules, and legacy patterns quietly reintroduced into the codebase. Whoever takes the suite under dev/tests/static seriously prevents exactly the kind of structural failure that only becomes visible at the next major upgrade or when module load order changes.
-
Maxim Mironjuk
-
January 05, 2025
Clickjacking tricks users with an invisible iframe layered over a real page, making them unknowingly trigger critical actions like deleting an account or confirming a transfer. Classic JavaScript frame-busting can be bypassed, while X-Frame-Options and the CSP directive frame-ancestors work as HTTP headers that reliably stop a page from being framed at all.
-
Maxim Mironjuk
-
January 05, 2025
Anyone maintaining a library or tool for multiple PHP or Node versions can hardly avoid test matrices. This article shows how parallel: matrix: in GitLab CI turns a single job definition into several parallel test runs, and how to balance runtime cost against test coverage.
-
Maxim Mironjuk
-
January 05, 2025
A schema with three different styles for the same thing costs every team time, patience, and trust in the API. Clear GraphQL naming conventions for types, fields, mutations and enums make a schema self-explanatory and can be anchored in a team for good with a style guide and linting.
-