laravel-enums
Laravel Enums
Enums provide type-safe, finite sets of values.
Related guides:
- State Machines - For complex state transitions
- Models - Model casts to enums
- DTOs - DTOs with enum properties
- form-requests.md - Enum validation
Always Use Backed Enums
Always use backed enums (string or int):
<?php
declare(strict_types=1);
More from leeovery/agentic-skills
laravel-quality
Code quality tooling with PHPStan, Pint, and strict types. Use when configuring or running static analysis, code style, or linting.
26laravel-testing
Comprehensive testing patterns with Pest. Use when writing or modifying tests, mocking, factories, or test patterns.
25laravel-query-builders
Custom query builders for type-safe, composable database queries. Use when creating or modifying query builders, query scopes, or complex database queries.
25laravel-architecture
High-level architecture decisions, patterns, and project structure. Use when deciding which pattern to use, organizing code, or making structural decisions.
23laravel-providers
Service providers, bootstrapping, and application configuration. Use when modifying service providers, booters, bootstrap logic, or app-level configuration.
23laravel-validation
Form request validation and comprehensive validation testing. Use when creating or modifying form requests, validation rules, or validation tests.
23