style(ecs): add easy-coding-standard to enforce coding style rules for php

- update .devcontainer settings: remove auto-formatting
for php + set intelephense as default formatter
- remove prettier php plugin as it lacks php 8 support
- add captain hook action for checking style pre-commit
- fix style with ecs on all files except views
This commit is contained in:
Yassine Doghri 2021-05-19 16:35:13 +00:00
commit aa1612342e
No known key found for this signature in database
GPG key ID: 3E7F89498B960C9F
230 changed files with 3420 additions and 5884 deletions

View file

@ -1,4 +1,6 @@
<?php namespace Tests\Support\Models;
<?php
namespace Tests\Support\Models;
use CodeIgniter\Model;
@ -8,6 +10,7 @@ class ExampleModel extends Model
* @var string
*/
protected $table = 'factories';
/**
* @var string
*/
@ -17,6 +20,7 @@ class ExampleModel extends Model
* @var string
*/
protected $returnType = 'object';
/**
* @var bool
*/
@ -36,10 +40,12 @@ class ExampleModel extends Model
* @var mixed[]
*/
protected $validationRules = [];
/**
* @var mixed[]
*/
protected $validationMessages = [];
/**
* @var bool
*/