wpmoo/wpmoo-coding-standards 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

wpmoo/wpmoo-coding-standards

Composer 安装命令:

composer require wpmoo/wpmoo-coding-standards

包简介

Shared PHPCS standard and custom sniffs for WPMoo projects.

README 文档

README

This repository contains the shared PHP_CodeSniffer (PHPCS) ruleset and custom sniffs used across WPMoo projects.

Installation

Add the package to your project as a development dependency. The package ships as a phpcodesniffer-standard, so the dealerdirect/phpcodesniffer-composer-installer plugin will automatically register the standard with PHPCS.

composer require --dev wpmoo/wpmoo-coding-standards

Usage

Reference the WPMoo standard from your project-level phpcs.xml or phpcs.xml.dist file:

<?xml version="1.0"?>
<ruleset name="Project Standard">
    <rule ref="WPMoo" />

    <file>public_html/wp-content/plugins/example-plugin</file>
</ruleset>

Run PHPCS as usual and it will apply the shared rules (WordPress Core + Docs + Extra, PHPCompatibilityWP) plus any custom sniffs provided by this package.

vendor/bin/phpcs

Development

  • The canonical ruleset lives in WPMoo/ruleset.xml.
  • Custom sniffs are placed under WPMoo/Sniffs following the PHPCS naming convention.
  • A local phpcs.xml.dist is provided so you can run the standard on this package itself via composer install && vendor/bin/phpcs.

Feel free to extend the rules or add additional sniffs to match the WPMoo guidelines.

统计信息

  • 总下载量: 2.53k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-10-23