public static function bootstrap($directory, $vendor = null, $initEnv = true)
    {
        $sep = DIRECTORY_SEPARATOR;
        if ($vendor === null) {
            $vendor = realpath(__DIR__ . $sep . '..' . $sep . '..' . $sep . '..');
        }
        $config = new self($directory, $initEnv);
        require(rtrim($vendor, $sep) . $sep . 'yiisoft' . $sep . 'yii2' . $sep . 'Yii.php');
        return $config;
    }
public static function bootstrap($directory, $vendor = null, $initEnv = true)
    {
        $sep = DIRECTORY_SEPARATOR;
        if ($vendor === null) {
            $vendor = realpath(__DIR__ . $sep . '..' . $sep . '..' . $sep . '..');
        }
        $config = new self($directory, $initEnv);
        require(rtrim($vendor, $sep) . $sep . 'yiisoft' . $sep . 'yii2' . $sep . 'Yii.php');
        return $config;
    }
public static function bootstrap ( $ directory , $ vendor = null , $ initEnv = true ) { $ sep = DIRECTORY_SEPARATOR ; if ( $ vendor === null ) { $ vendor = realpath ( __DIR__ . $ sep . '..' . $ sep . '..' . $ sep . '..' ) ; } $ config = new self ( $ directory , $ initEnv ) ; require ( rtrim ( $ vendor , $ sep ) . $ sep . 'yiisoft' . $ sep . 'yii2' . $ sep . 'Yii.php' ) ; return $ config ; }
Init the configuration for the given directory and load the Yii bootstrap file.

@param string $directory the application directory
@param string|null $vendor the composer vendor directory. Default is `null`
which means, the vendor directory is autodetected.
@param bool $initEnv whether to initialize the Yii environment. Default is `true`.
@return static the Config instance for that application directory
Init the configuration for the given directory and load the Yii bootstrap file .