utopia-php/preloader

Utopia Preloader library is simple and lite library for managing PHP preloading configuration

Maintainers

👁 eldadfux

Package info

github.com/utopia-php/preloader

pkg:composer/utopia-php/preloader

Statistics

Installs: 280 997

Dependents: 1

Suggesters: 0

Stars: 12

Open Issues: 0

0.2.4 2020-10-24 07:04 UTC

Requires

  • php: >=7.1

Requires (Dev)

Suggests

None

Provides

None

Conflicts

None

Replaces

None

MIT 65ef48392e72172f584b0baa2e224f9a1cebcce0

  • Eldad Fux <team.woop@appwrite.io>

frameworkphppreloadupfpreloadingpreloaderutopia

This package is auto-updated.

Last update: 2026-06-10 09:39:43 UTC


README

👁 Build Status
👁 Discord
👁 Total Downloads

Utopia Preloader library is a simple and lite library for managing PHP preloading configuration. This library is aiming to be as simple as possible and easy to learn and use. This library is maintained by the Appwrite team.

Although this library is a part of the Utopia Framework project it is dependency free and can be used as standalone with any other PHP project or framework.

Getting Started

Install using composer:

composer require utopia-php/preloader
<?php

if (file_exists(__DIR__.'/../vendor/autoload.php')) {
 require __DIR__.'/../vendor/autoload.php';
}

use Utopia\Preloader;

(new Preloader())
 ->paths(realpath(__DIR__ . '/../app/config'))
 ->paths(realpath(__DIR__ . '/../src'))
 ->ignore(realpath(__DIR__ . '/../vendor/twig/twig'))
 ->ignore(realpath(__DIR__ . '/../vendor/guzzlehttp/guzzle'))
 ->ignore(realpath(__DIR__ . '/../vendor/geoip2'))
 ->ignore(realpath(__DIR__ . '/../vendor/maxmind'))
 ->ignore(realpath(__DIR__ . '/../vendor/maxmind-db'))
 ->ignore(realpath(__DIR__ . '/../vendor/piwik'))
 ->load();

System Requirements

Utopia Framework requires PHP 8.0 or later. Preloading is supported in PHP 7.4 or later. We recommend using the latest PHP version whenever possible.

Copyright and license

The MIT License (MIT) http://www.opensource.org/licenses/mit-license.php