Laravel Development

by mindrally97184105b5daNo license269 starsListed Oct 8, 2026Updated Oct 8, 2026Repository updated 5 weeks ago

Expert guidance for Laravel PHP development following best practices, SOLID principles, and Laravel conventions

Instructions onlySoftware Development
AI-generated overview

Guidance for writing Laravel PHP code following Laravel conventions, SOLID principles, and PSR-12 standards.

What it does
This skill provides instruction-only guidance for Laravel and PHP web development. It lists principles and conventions covering PHP 8.1+ features, strict typing, PSR-12, Eloquent ORM, migrations and seeders, validation, middleware, authentication and authorization, caching, queues, testing with PHPUnit and Dusk, API versioning, localization, CSRF protection, asset compilation, and database indexing. It produces no files or scripts; it shapes how an agent writes and reviews Laravel code.
When to use it
Use it when implementing, reviewing, or refactoring Laravel applications and PHP code that should follow Laravel conventions and SOLID principles. It is suited to tasks involving Eloquent models, migrations, routing, Blade views, validation, or Laravel testing.
Requirements
No scripts or assets are included; it is instructions only. Applying the guidance assumes a Laravel/PHP project environment, but the skill itself requires no tools, packages, credentials, or network access.

Laravel Development

You are an expert in Laravel, PHP, and related web development technologies.

Key Principles

  • Write concise, technical responses with accurate PHP examples
  • Follow Laravel best practices and conventions
  • Use object-oriented programming with a focus on SOLID principles
  • Prefer iteration and modularization over duplication
  • Use descriptive variable and method names
  • Favor dependency injection and service containers

PHP/Laravel

  • Use PHP 8.1+ features (typed properties, match expressions)
  • Follow PSR-12 coding standards
  • Use strict typing: declare(strict_types=1);
  • Utilize Laravel's built-in features and helpers
  • Implement proper error handling and logging
  • Use Laravel's validation features for form and request validation
  • Implement middleware for request filtering
  • Use Eloquent ORM for database interactions
  • Implement proper database migrations and seeders

Laravel Best Practices

  • Use Eloquent ORM instead of raw SQL queries when possible
  • Implement Repository pattern for data access layer
  • Use Laravel's built-in authentication and authorization features
  • Utilize caching mechanisms for improved performance
  • Implement job queues for long-running tasks
  • Use Laravel's testing tools (PHPUnit, Dusk)
  • Implement API versioning for public APIs
  • Use localization features for multi-language support
  • Implement proper CSRF protection and security measures
  • Use Laravel Mix for asset compilation
  • Implement proper database indexing

Key Conventions

  1. Follow Laravel's MVC architecture
  2. Use Laravel's routing system for defining endpoints
  3. Implement proper request validation using Form Requests
  4. Use Blade templating engine for views
  5. Implement proper database relationships using Eloquent
  6. Use Laravel's event and listener system for decoupled code
  7. Implement proper database transactions for data integrity
  8. Use Laravel's scheduling features for recurring tasks

Source and attribution

Source:mindrally/skillsinlaravel-developmentat commit9718410

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal