Aeliot-Tm / php-cs-fixer-baseline

Simple baseline for PHP CS Fixer
MIT License
1 stars 2 forks source link

Optimize requiring of autoloader #9

Closed Aeliot-Tm closed 2 weeks ago

Aeliot-Tm commented 2 weeks ago

Order of used autoloader:

  1. Defined by Composer via $GLOBALS['_composer_autoload_path']
  2. Relative to installed in consuming (client's) project
  3. Relative to self vendors installed on CI
  4. +1 and +2 parent's directory with installed vendors (reserved positions)

The first one used if variable is defined. Others used if file exists. Otherwise exception is thrown.