How To Use Laravel Libraries In Laravel Project Without Composer

- 1 answer

I have libraries which I used to use repeatedly and have to be able to add it to Laravel project with the version I already download it before on local and may use it event with no internet connection is it possible to add it to Laravel in some way like Composer or is it possible to build my own local composer?



You can use the autoload mapping in order to adchieve that. Just create a folder with the file/files that you want to use. For example:


And store the files right there. Then you just have to use the composer classmap: Edit the composer.json file indicating the path to your classes:

"autoload": {
    "classmap": [

Run the composer dump-autoload command and you'll be ready to go.