Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce custom PSR-4 autoload if not using composer #419

Merged
merged 1 commit into from
Aug 17, 2018

Conversation

julienbourdeau
Copy link

Q A
Bug fix? no
New feature? yes
BC breaks? no
Related Issue Fix #...
Need Doc update yes

What was changed

Adding a custom autoload. If you don't use composer, you can require the new autoload.php.

Example:

<?php

require 'lib/algolia/autoload.php'; # example path

$client  = Client::create();

Why it was changed

Some older projects (WordPress, Drupal 7, and such) aren't using composer for autoloading). For v1, they rely on a file that require all the existing file: algoliasearch.php.

This new file sets a custom autoloader instead of requiring all the things.

@julienbourdeau julienbourdeau force-pushed the 2.0 branch 4 times, most recently from 4c6e3ec to d66c3c0 Compare August 16, 2018 13:37
@julienbourdeau julienbourdeau merged commit 1ca5526 into 2.0 Aug 17, 2018
@julienbourdeau julienbourdeau deleted the feat/autoload-legacy branch August 17, 2018 08:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant