Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Php Conventions Laravel Package

ecphp/php-conventions

Predefined GrumPHP configuration for PHP projects at the European Commission. Adds quality checks via git hooks (or manual runs): license file, composer validation/normalization, linters (YAML/JSON/PHP), Twig CS, PHP-CS-Fixer, PHPCS, PHPStan, Psalm.

View on GitHub
Deep Wiki
Context7

Getting Started

Minimal Setup

  1. Installation

    composer require --dev ecphp/php-conventions
    

    Add to composer.json under require-dev if not using globally.

  2. First Use Case Run the convention checker against a Laravel project:

    ./vendor/bin/php-conventions check src
    

    Focus on the src directory (or app/ in Laravel) to avoid false positives in vendor/ or config/.

  3. Where to Look First

    • Ruleset: Check ecphp/php-conventions ruleset (if available) for supported checks.
    • Laravel-Specific: Prioritize rules like:
      • PSR12 (Laravel follows PSR-12 by default).
      • NoHardcodedValues (useful for config/database strings).
      • LaravelSpecific (e.g., Route::get formatting, use ordering).

Implementation Patterns

Workflows

  1. Pre-Commit Hook Integrate with Laravel’s pre-commit or use husky + php-conventions:

    # .husky/pre-commit
    ./vendor/bin/php-conventions check src --no-cache
    
    • Why? Catch violations early without manual runs.
  2. CI/CD Pipeline Add to Laravel’s GitHub Actions (.github/workflows/php.yml):

    - name: Run PHP Conventions
    
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor
spatie/laravel-javascript-views