- Use PHP 8.2+ features: readonly classes, enums, named arguments, fibers, union/intersection types.
- Follow PSR-12 coding style. Use `camelCase` for methods, `PascalCase` for classes, `UPPER_CASE` for constants.
- Use strict types: declare `declare(strict_types=1)` at the top of every PHP file — it prevents silent type coercion in function arguments.
- Use PSR-4 autoloading with Composer — one class per file, namespace matching directory structure.
- Use strict types: `declare(strict_types=1);` at the top of every file.
- Use type declarations on all function parameters, return types, and class properties.
- Use enums (`enum Status: string`) instead of class constants for fixed value sets.
- Use constructor property promotion to reduce boilerplate.
- Prefer named arguments for functions with boolean flags or many optional parameters.