Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Roll your own micro framework

Niklas Modess
September 07, 2015

Roll your own micro framework

Are micro frameworks the future? When you choose a framework your often have to make compromises and you couple your code to the framework itself. Let’s explore how we can create our own micro framework we can tailor for our application’s needs and how it fits well in a service oriented architecture.

Niklas Modess

September 07, 2015
Tweet

Other Decks in Programming

Transcript

  1. Me, myself & I Niklas Modess Remote freelancer / consultant

    Organizer of Laravel Stockholm meetup group Author of Deploying PHP Appplications Blogger at http://modess.io @niklasmodess
  2. Simple RESTful API with Laravel? 4 classpreloader/classpreloader 4 danielstjules/stringy 4

    doctrine/inflector 4 jeremeamia/superclosure 4 league/flysystem 4 monolog/monolog 4 mtdowling/cron-expression
  3. S.O.L.I.D 4 Single responsibility principle 4 Open/closed principle 4 Liskov

    substitution principle 4 Interface segregation principle 4 Dependency inversion principle
  4. we do this... <?php $container = require __DIR__ . '/bootstrap.php';

    $router = $container->get('Router'); // some code.. $router->dispatch();
  5. Let's build stuff 4 Application container (DI/IoC) 4 Router interface

    4 Router implementations 4 Hot-swapping router implementations