PHPackages                             aura/autoload - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. aura/autoload

ActiveLibrary[PSR &amp; Standards](/categories/psr-standards)

aura/autoload
=============

Provides a PSR-4 compliant autoloader implementation.

2.0.4(9y ago)94476.8k—2.6%22[3 issues](https://github.com/auraphp/Aura.Autoload/issues)12BSD-2-ClausePHPPHP &gt;=5.3.0

Since Nov 27Pushed 9y ago11 watchersCompare

[ Source](https://github.com/auraphp/Aura.Autoload)[ Packagist](https://packagist.org/packages/aura/autoload)[ Docs](https://github.com/auraphp/Aura.Autoload)[ RSS](/packages/aura-autoload/feed)WikiDiscussions 2.x Synced 1mo ago

READMEChangelog (6)DependenciesVersions (12)Used By (12)

Aura.Autoload
=============

[](#auraautoload)

Provides a full PSR-4 and limited PSR-0 autoloader. Although it is installable via Composer, its best use is probably outside a Composer-oriented project.

For a full PSR-0 only autoloader, please see [Aura.Autoload v1](https://github.com/auraphp/Aura.Autoload/tree/develop).

Foreword
--------

[](#foreword)

### Installation

[](#installation)

This library requires PHP 5.3 or later; we recommend using the latest available version of PHP as a matter of principle. It has no userland dependencies.

It is installable and autoloadable via Composer as [aura/autoload](https://packagist.org/packages/aura/autoload).

Alternatively, [download a release](https://github.com/auraphp/Aura.Autoload/releases) or clone this repository, then require or include its *autoload.php* file.

### Quality

[](#quality)

[![Scrutinizer Code Quality](https://camo.githubusercontent.com/b27c14f48af4578a8a1984a48b606c49a9b9e0b87c00dd464b849d6b86ea2660/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f617572617068702f417572612e4175746f6c6f61642f6261646765732f7175616c6974792d73636f72652e706e673f623d646576656c6f702d32)](https://scrutinizer-ci.com/g/auraphp/Aura.Autoload/)[![Code Coverage](https://camo.githubusercontent.com/939987ade7b97f78c9825c208dfca23ec06aa883e8ff98a7e694e7cc44dc3c5a/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f617572617068702f417572612e4175746f6c6f61642f6261646765732f636f7665726167652e706e673f623d646576656c6f702d32)](https://scrutinizer-ci.com/g/auraphp/Aura.Autoload/)[![Build Status](https://camo.githubusercontent.com/98f38ec5d3596b1105e38658ee105998cbdd05d0933dd614c538b4ac72647ded/68747470733a2f2f7472617669732d63692e6f72672f617572617068702f417572612e4175746f6c6f61642e706e673f6272616e63683d646576656c6f702d32)](https://travis-ci.org/auraphp/Aura.Autoload)

To run the unit tests at the command line, issue `phpunit` at the package root. (This requires [PHPUnit](http://phpunit.de/manual/) to be available as `phpunit`.)

This library attempts to comply with [PSR-1](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-1-basic-coding-standard.md), [PSR-2](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md), and [PSR-4](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md). If you notice compliance oversights, please send a patch via pull request.

### Community

[](#community)

To ask questions, provide feedback, or otherwise communicate with the Aura community, please join our [Google Group](http://groups.google.com/group/auraphp), follow [@auraphp on Twitter](http://twitter.com/auraphp), or chat with us on #auraphp on Freenode.

Getting Started
---------------

[](#getting-started)

To use the autoloader, first instantiate it, then register it with SPL autoloader stack:

```

```

### PSR-4 Namespace Prefixes

[](#psr-4-namespace-prefixes)

To add a namespace conforming to [PSR-4](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md) specifications, point to the base directory for that namespace. Multiple base directories are allowed, and will be searched in the order they are added.

```
