szepeviktor/phpcs-psr-12-neutron-hybrid-ruleset
Hybrid PHP_CodeSniffer ruleset for OOP WordPress: PSR-12 Extended formatting plus Neutron/WPCS checks, strict types, file permissions, docblocks, and selected Slevomat rules. Install via Composer and run phpcs with PSR12NeutronRuleset.
chmod vulnerabilities or SQL injection risks via WPCS rules). Critical for Laravel plugins interacting with WordPress databases.global variables) that would require excessive rule overrides, making the hybrid approach impractical.*"This package lets us standardize coding practices for Laravel-WordPress hybrid projects—like Automattic’s Neutron ruleset—without reinventing the wheel. It’s a maintained, zero-upfront-cost solution that:
*"This hybrid ruleset combines PSR-12 (Laravel formatting) + Neutron (WordPress OOP) + Slevomat (advanced static analysis) into one PHPCS standard. Here’s why it’s worth adopting:
--standard=PSR12NeutronRuleset.phpcs commands; add it to your pipeline in 5 minutes.WordPress.DB for Laravel’s Eloquent) via ruleset.xml.
Tradeoffs:*"This ruleset hardens our Laravel-WordPress integrations by:
chmod vulnerabilities (common in shared hosting).
Critical for: Projects like [Headless WordPress API] where Laravel exposes WordPress data to external clients.
Ask: Should we block PRs with PHPCS errors in CI, or start with warnings?"*How can I help you explore Laravel packages today?