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

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

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

developion/coding-standards

最新稳定版本:1.1.4

Composer 安装命令:

composer require developion/coding-standards

包简介

README 文档

README

Based on PSR12, a few targeted tweaks and fixers are aimed to general consistency of the code.

Requirements

  • PHP 8.2+

Installation

composer require --dev developion/coding-standards

ECS

Add ecs.php to the root of your project, and set the content to:

use Developion\CodingStandards\SetList;

$config = require SetList::DEVELOPION;

return $config->withPaths([
		__DIR__ . '<PATH>',
		__FILE__,
	]);

The line __DIR__ . '<PATH>' deserves special attention, as it needs to be configured to point to the code of the project that needs to be checked. If necessary, it can be duplicated as many times as necessary.

PHP CS Fixer

Add .php-cs-fixer.php to the root of your project, and set the content to:

use Developion\CodingStandards\SetList;
use PhpCsFixer\Finder;

$finder = (new Finder())
	->in([
		__DIR__ . '<PATH>',
	])
	->ignoreDotFiles(false)
	->ignoreVCSIgnored(true)
	->exclude([
		__DIR__ . '/vendor',
	])
;

$config = require SetList::PHP_CS_FIXER;

return $config($finder);

Adjust the <PATH> to your code accordingly.

TODO: add VS Code config

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-03-17

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固