title: Fatal Error: Class not Found when using namespaces
body: <p>I have been trying to use namespaces for the first time in ages and I am running into the below problem. I am currently using Composer for a PSR-4 autoloader and I keep getting the error:
  <code>Fatal error: Class 'API\Library\Config' not found in C:\wamp64\www\project\src\index.php on line 14</code></p>
  
  <p>composer.json</p>
  
  <pre><code>"autoload": {
      "psr-4": {
          "API\\": "src",
          "API\\Library\\": "src/Library",
          "API\\Controllers\\": "src/Application/Controllers"
      }
  }
  </code></pre>
  
  <p>src/index.php</p>
  
  <pre><code>namespace API;
  include_once('vendor/autoload.php');
  use API\Library\Config;
  $config = new Config(); //line 18
  </code></pre>
  
  <p>The Folder layout is as such:</p>
  
  <p><a href="https://i.stack.imgur.com/mpUnl.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/mpUnl.png" alt="folder layout"></a></p>