Skip to content

Latest commit

 

History

History
35 lines (29 loc) · 926 Bytes

File metadata and controls

35 lines (29 loc) · 926 Bytes

php-enum-utils — Project Conventions

Project

Zero-dependency PHP 8.1+ toolkit for native enums. Namespace: Kexxt\EnumUtils.

Code Style

  • PER-CS (PHP-FIG PER Coding Style)
  • Single quotes, short array syntax, trailing commas in multiline
  • Run: composer lint

Commit Format

  • feat: new feature
  • fix: bug fix
  • test: tests
  • docs: documentation
  • refactor: refactoring
  • chore: tooling/config

Testing

  • Framework: Pest v3
  • Run: composer test
  • Test files: tests/ directory, named *Test.php
  • Fixture enums: tests/Fixtures/

Static Analysis

  • PHPStan level 9
  • Run: composer analyse

Architecture

  • src/EnumUtilsTrait.php — main trait for BackedEnum
  • src/EnumCollection.php — collection operations
  • src/Contracts/ — interfaces
  • src/Integration/Laravel/ — Laravel cast
  • src/Integration/Doctrine/ — Doctrine type
  • src/Validation/ — validation rules