I noticed that we need to user vendor/autoloader.php instead of the old slim autoloader.
Will it be possible to provide usage of both options in the future?
The current project I am wokring on have no wish to use composer, this requirement seems to lock us to an old version of Slim.
Why the sudden reliance of 3. party libraries?
Why the sudden reliance of 3. party libraries?
Because some things have been solved better than we can. Autoloading is a good example. Composer's is much better than Slim 2's.
Why the sudden reliance of 3. party libraries?
Because some things have been solved better than we can. Autoloading is a good example. Composer's is much better than Slim 2's.
Just went through your old slim.php, and yes, its a bit long.
Would it be possible for you to take the autoloading part from composer, then isolate the logic that is needed to create a re-implementation of slim.php?
It just seems strange to me that auto loading would be the only reason for relying on Composer.
We use Composer for the FastRoute routing library, Pimple DI container and the PSR-7 interfaces in Slim 3.
Building applications with 3rd party libraries managed by Composer is the way of the future for modern PHP development.
See https://akrabat.com/using-composer-with-shared-hosting/ for strategies on how to use it for local development, but not on your live platform.
We have to agree to disagree on that.
No any PHP framework / subsystem can claim to be the only way of the future, it will depend on the situation.
In this situation we have our own autoloader repository framework, and Composer is just not compatible with it... yet.
We could put a lot of time and effort into making it compatible, but there is no guarantee that it wont happen again with another framework / subsystem.
This forces me to make a choice based on price and practicality.
I can either ditch slim for another PHP restfull API implementation, or I can use the old version limiting future updates.
Since it seems there will not be taken action to actually free Slim from the composer dependencies I will close this issue, unless something comes up in the next two days.
Thank you for your time.
If the current version of Slim 2.* works for you, then I would suggest keep using it. The entire PHP community is moving towards sharing components and composer is a way of doing this. You can install Slim 3 without composer if you wish, but you will have to deal with all the wiring yourself.
I think you should consider updating your Autoloader to work with PSR4 as this is becoming the standard of autoloaders in the PHP ecosystem.
It just seems strange to me that auto loading would be the only reason for relying on Composer.
We rely on Composer for more than autoloading, it is used for dependency management. It allows for faster getting and including a package from the wider PHP eco-system without having to fiddle with how to load these packages.
Most helpful comment
If the current version of Slim 2.* works for you, then I would suggest keep using it. The entire PHP community is moving towards sharing components and composer is a way of doing this. You can install Slim 3 without composer if you wish, but you will have to deal with all the wiring yourself.
I think you should consider updating your Autoloader to work with PSR4 as this is becoming the standard of autoloaders in the PHP ecosystem.