1

I am following the following tutorial

http://www.gufran.me/post/laravel-illuminate-router-package-in-your-application/

My composer.json looks like this

{
    "name": "superior/siginin",
    "description": "Sign In Example",
    "authors": [
        {
            "name": "A G",
            "email": "ag@gmail.com"
        }
    ],
    "require": {
        "illuminate/routing":"*",
        "illuminate/events":"*"
    }
}

My index.php looks like this..

<?php
/**
 * User: ag
 * Date: 2/27/17
 * Time: 10:08 AM
 */

require 'vendor/autoload.php';
require 'vendor/illuminate/support/helpers.php';
$basePath = str_finish(dirname(__FILE__), '/');
$controllersDirectory = $basePath . 'Controllers';
$modelsDirectory = $basePath . 'Models';

// register the autoloader and add directories
Illuminate\Support\ClassLoader::register();
Illuminate\Support\ClassLoader::addDirectories(array($controllersDirectory, $modelsDirectory));

For some strange Reason Illuminate\Support\ClassLoader was not loaded into my page

Does anyone have a clue to why this is. The version of Illuminate\Routing it added was v5.4.13

according to the api. It should be in there.

numerical25
  • 10,524
  • 36
  • 130
  • 209
  • did you update the classmap? Read more here: http://stackoverflow.com/questions/25619063/composer-classmap-autoload-does-not-load-new-files-in-folder – JustOnUnderMillions Feb 27 '17 at 15:33
  • I understand what your saying. As far as doing the ClassLoading within the composer.json file instead. But still, It doesn't explain why when I go to https://laravel.com/api/5.4/Illuminate/Support/ClassLoader.html I can see the Class is clearly there but when I look into my vendor files. its not. – numerical25 Feb 27 '17 at 16:10
  • That worked for me but I just need to know why composer did not add a Class that should be in there – numerical25 Feb 27 '17 at 16:45
  • In api docs ( https://laravel.com/api/5.4/Illuminate/Support/ClassLoader.html ) ClassLoader is present, but not in source code ( https://github.com/illuminate/support/tree/5.4 ). – Odin Thunder Sep 11 '17 at 12:27

0 Answers0