SlideShare a Scribd company logo
Laravel 5 New Features
Joe Ferguson
Before we begin
Have Virtualbox (virtualbox.org) Installed
Have VirtualBox Extension Pack Installed
Have Vagrant (vagrantup.com) Installed
run: vagrant box add laravel/homestead
New Directory Structure
Laravel 5 Directory
App directory now "Your Application" / "Entry point to app”
Laravel 4 Artisan Commands -> Console in App folder
Web stuff in Http
Controllers all have name space
filters.php -> Broken out into separate classes/files.
More focus on Service Providers -> Filter Service Providers
No more global.php -> Use service providers
Removed models directory. Can be just in app folder. PSR-4 default
Don't like the app namespace? artisan app:name MyApplication
Blade Changes
Laravel 4 uses {{ to echo and {{{ To echo escaped
Laravel 5 {{ and {{{ will echo escaped and {!! is used to echo raw
Biggest impact is likely form helpers: {!! Form::open() !!}
Commands
Commands (app/Commands) - Message containing only info needed
to do something
Command Handler (app/Handlers/Commands) - Class that does
something in response to a command
Command Bus - Allows dispatch of commands, matches commands
to handlers
Self handling commands just need a handle() method on the
command & implements SelfHandling
Events
Events (app/Events)
Events have handlers (similar to Commands)
Bind Events via appProvidersEventServiceProvider.php
Events inform the system something happened VS demanding
action from the system
Form Requests
Special class for validating and authorizing form submissions
Each class has rules() (returns array) and authorize() (returns boolean) methods
Benefit of rules & authorize being methods is you can perform logic
Type Hinting your forms to the Form Request will automatically validate your
forms
If validation fails, errors will be available to the view and redirected back.
This happens because the FormRequestServiceProvider listens for anything being
resolved is instance of FormRequest and calls the validate method.
Helpers
view() - Get a View instance for the given view path
action() - Generate a URL for a given controller action
app_path() - Get the fully qualified path to the app directory
asset() - Generate a URL for an asset.
Routing – get(), delete(), put()
Route Caching
artisan route:cache
Serializes your routes.php
Benefits: Faster routing
Drawback: Must run artisan route:clear on every routes.php
change
Middleware
Implements decorator pattern. request -> does work -> returns object to next
layer
Laravel uses middleware for Encrypting/Decrypting cookies, Reading/Writing
Sessions
artisan make:middleware MyMiddleware (app/Http/Middleware)
Middleware registered in app/Http/Kernel.php
Can run before or after the request has been processed.
Easiest example would be auth
Controller Method Injection
Can inject dependencies into methods, no longer via constructor
Purpose is to help developers write cleaner code
Changes to Illuminate Packages
Form or HTML helpers no longer in Core, must be pulled in via
composer.
add "laravelcollective/html": "~5.0" to composer
update config/app.php
Elixir
API for defining basic Gulp tasks for your app.
Requires nodejs
Put your sass/less files in resources/assets/sass|less
Can trigger sass/less/phpunit/phpspec, combine stylesheets
Socialite
Easy to use social logins with oauth
Supports Facebook, Twitter, Google, Github, and Bitbucket
Contracts
Set of interfaces that define the core services provided by the
framework
Depend on abstractions, not concrete dependencies.
Write code that doesn't have to be aware of the laravel framework
Upgrade from 4.2 to 5
Fresh install Laravel 5
Update Dependencies /Packages
Namespace (somewhat optional for now)
Migrate environment variables
Move routes to app/Http/routes.php
Move controllers to app/Http/Controllers (add this to classmap)
Copy route bindings to boot() in app/Providers/RouteServiceProvider.php
Add route facade to RouteServiceProvider.php to continue using Route facade
CSRF is now global. Use middleware to disable if needed
Move models to app/Models. Add app/Models to classmap in composer.json
Update your user auth to use Laravel 5’s auth system
Move commands to app/Console/Commands. Add app/Console/Commands to classmap in composer.json
Move migrations to database/migrations, Database Seeds to database/seeds
… and more!
Upgrade from 4.2 to 5
http://laravel.com/docs/5.0/upgradeFresh install Laravel 5
Update Dependencies /Packages
Namespace (somewhat optional for now)
Migrate environment variables
Move routes to app/Http/routes.php
Move controllers to app/Http/Controllers (add this to classmap)
Copy route bindings to boot() in app/Providers/RouteServiceProvider.php
Add route facade to RouteServiceProvider.php to continue using Route facade
CSRF is now global. Use middleware to disable if needed
Move models to app/Models. Add app/Models to classmap in composer.json
Update your user auth to use Laravel 5’s auth system
Move commands to app/Console/Commands. Add app/Console/Commands to classmap in composer.json
Move migrations to database/migrations, Database Seeds to database/seeds
… and more!
Homestead
“Laravel Homestead is an official, pre-packaged
Vagrant "box" that provides you a wonderful
development environment without requiring you
to install PHP, HHVM, a web server, and any
other server software on your local machine. No
more worrying about messing up your operating
system! Vagrant boxes are completely disposable.
If something goes wrong, you can destroy and re-
create the box in minutes!”
What’s in the box:
• Ubuntu 14.04
• PHP 5.6
• HHVM
• Nginx
• MySQL
• Postgres
• Redis
• NodeJS
• Bower
• Grunt
• Gulp
• Beanstalkd
• Memcached
• Laravel Envoy
Fabric + HipChat Extension + more!
Getting Homestead
Install the box:
vagrant box add laravel/homestead
Getting Homestead
If you have PHP installed locally:
composer global require "laravel/homestead=~2.0"
Make sure to place the ~/.composer/vendor/bin directory in your
PATH so the homestead executable is found when you run the
homestead command in your terminal.
Homestead 2.0
Significant change over previous 1.x versions
Uses homestead from your home folder
Less vagrant stuff in your projects (if you don’t like that
sort of thing)
How I use Homestead
https://github.com/svpernova09/HomesteadSkeleton
Drop in Homestead files to project
Each project has an isolated vagrant environment
Easier to share dev environment settings

More Related Content

What's hot (20)

PDF
Why Laravel?
Jonathan Goode
 
PDF
Laravel 5.4
Nisha Patel
 
PPTX
Introduction to Laravel Framework (5.2)
Viral Solani
 
PDF
Adventures in Laravel 5 SunshinePHP 2016 Tutorial
Joe Ferguson
 
PDF
All the Laravel Things – Up & Running to Making $$
Joe Ferguson
 
PPTX
A introduction to Laravel framework
Phu Luong Trong
 
PPTX
What's New in Laravel 5 (Laravel Meetup - 23th Apr 15, Yogyakarta, ID)
Roes Wibowo
 
PDF
Laravel Introduction
Ahmad Shah Hafizan Hamidin
 
PDF
php[world] 2015 Laravel 5.1: From Homestead to the Cloud
Joe Ferguson
 
PDF
php[world] 2015 Training - Laravel from the Ground Up
Joe Ferguson
 
PDF
Laravel Forge: Hello World to Hello Production
Joe Ferguson
 
PDF
What's New In Laravel 5
Darren Craig
 
PPTX
10 Laravel packages everyone should know
Povilas Korop
 
PDF
Getting to know Laravel 5
Bukhori Aqid
 
ODP
Presentation laravel 5 4
Christen Gjølbye Christensen
 
PDF
Digpen 7: Why choose Laravel?
John Blackmore
 
PPTX
Laravel overview
Obinna Akunne
 
PPTX
Laravel Beginners Tutorial 1
Vikas Chauhan
 
PPTX
Workshop Laravel 5.2
Wahyu Rismawan
 
PDF
Laravel Forge: Hello World to Hello Production
Joe Ferguson
 
Why Laravel?
Jonathan Goode
 
Laravel 5.4
Nisha Patel
 
Introduction to Laravel Framework (5.2)
Viral Solani
 
Adventures in Laravel 5 SunshinePHP 2016 Tutorial
Joe Ferguson
 
All the Laravel Things – Up & Running to Making $$
Joe Ferguson
 
A introduction to Laravel framework
Phu Luong Trong
 
What's New in Laravel 5 (Laravel Meetup - 23th Apr 15, Yogyakarta, ID)
Roes Wibowo
 
Laravel Introduction
Ahmad Shah Hafizan Hamidin
 
php[world] 2015 Laravel 5.1: From Homestead to the Cloud
Joe Ferguson
 
php[world] 2015 Training - Laravel from the Ground Up
Joe Ferguson
 
Laravel Forge: Hello World to Hello Production
Joe Ferguson
 
What's New In Laravel 5
Darren Craig
 
10 Laravel packages everyone should know
Povilas Korop
 
Getting to know Laravel 5
Bukhori Aqid
 
Presentation laravel 5 4
Christen Gjølbye Christensen
 
Digpen 7: Why choose Laravel?
John Blackmore
 
Laravel overview
Obinna Akunne
 
Laravel Beginners Tutorial 1
Vikas Chauhan
 
Workshop Laravel 5.2
Wahyu Rismawan
 
Laravel Forge: Hello World to Hello Production
Joe Ferguson
 

Viewers also liked (12)

PDF
From CakePHP to Laravel
Jason McCreary
 
PPTX
Laravel : A Fastest Growing Kid
Endive Software
 
PDF
Intro to Laravel 4
Singapore PHP User Group
 
PDF
Laravel 5
lukzgois
 
PDF
Laravel 5
Rik Heywood
 
PPT
1 electronic data interchange (edi)
gauravashq
 
PPTX
Laravel 5 and SOLID
Igor Talevski
 
PPTX
Domain Driven Design using Laravel
wajrcs
 
PPT
ELECTRONIC DATA INTERCHANGE
alraee
 
PPTX
Advantages and Disadvantages of Technology
09356506910
 
PDF
Introduction à Laravel 4 @Dogstudio
Nicolas Widart
 
PDF
PHP 7.0 : aperçu des nouveautés
Didcode
 
From CakePHP to Laravel
Jason McCreary
 
Laravel : A Fastest Growing Kid
Endive Software
 
Intro to Laravel 4
Singapore PHP User Group
 
Laravel 5
lukzgois
 
Laravel 5
Rik Heywood
 
1 electronic data interchange (edi)
gauravashq
 
Laravel 5 and SOLID
Igor Talevski
 
Domain Driven Design using Laravel
wajrcs
 
ELECTRONIC DATA INTERCHANGE
alraee
 
Advantages and Disadvantages of Technology
09356506910
 
Introduction à Laravel 4 @Dogstudio
Nicolas Widart
 
PHP 7.0 : aperçu des nouveautés
Didcode
 
Ad

Similar to Laravel 5 New Features (20)

PPTX
Laravel development (Laravel History, Environment Setup & Laravel Installatio...
Dilouar Hossain
 
PDF
Web services with laravel
Confiz
 
PPTX
Laravel 5
Sudip Simkhada
 
PDF
Laravel (8) php_framework_handbook__start_from_zer_18604872_(z-lib.org)
ssuser337865
 
PPT
Web service with Laravel
Abuzer Firdousi
 
PDF
laravel-interview-questions.pdf
AnuragMourya8
 
ODP
Laravel 5.3 - Web Development Php framework
Swapnil Tripathi ( Looking for new challenges )
 
PPTX
cakephp UDUYKTHA (1)
Varsha Krishna
 
PDF
Laravel presentation
Toufiq Mahmud
 
PPTX
Getting started with laravel
Advance Idea Infotech
 
PPT
An Introduction to Websphere sMash for PHP Programmers
jphl
 
PPTX
Lecture 2_ Intro to laravel.pptx
SaziaRahman
 
PDF
Object Oriented Programming with Laravel - Session 2
Shahrzad Peyman
 
PPTX
Getting started with WordPress development
Steve Mortiboy
 
PPTX
Laravel and artisan cli
Sayed Ahmed
 
PPTX
Phalcon 2 - PHP Brazil Conference
Jackson F. de A. Mafra
 
PPTX
introduction to web programming using PHP
vishnupriyapm4
 
PPTX
Laravel Introduction Module 1 Presentation
Raduelico
 
PDF
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Mack Hardy
 
PDF
Hidden things uncovered about laravel development
Katy Slemon
 
Laravel development (Laravel History, Environment Setup & Laravel Installatio...
Dilouar Hossain
 
Web services with laravel
Confiz
 
Laravel 5
Sudip Simkhada
 
Laravel (8) php_framework_handbook__start_from_zer_18604872_(z-lib.org)
ssuser337865
 
Web service with Laravel
Abuzer Firdousi
 
laravel-interview-questions.pdf
AnuragMourya8
 
Laravel 5.3 - Web Development Php framework
Swapnil Tripathi ( Looking for new challenges )
 
cakephp UDUYKTHA (1)
Varsha Krishna
 
Laravel presentation
Toufiq Mahmud
 
Getting started with laravel
Advance Idea Infotech
 
An Introduction to Websphere sMash for PHP Programmers
jphl
 
Lecture 2_ Intro to laravel.pptx
SaziaRahman
 
Object Oriented Programming with Laravel - Session 2
Shahrzad Peyman
 
Getting started with WordPress development
Steve Mortiboy
 
Laravel and artisan cli
Sayed Ahmed
 
Phalcon 2 - PHP Brazil Conference
Jackson F. de A. Mafra
 
introduction to web programming using PHP
vishnupriyapm4
 
Laravel Introduction Module 1 Presentation
Raduelico
 
Strategies and Tips for Building Enterprise Drupal Applications - PNWDS 2013
Mack Hardy
 
Hidden things uncovered about laravel development
Katy Slemon
 
Ad

More from Joe Ferguson (20)

PDF
Modern infrastructure as code with ansible cake fest 2021
Joe Ferguson
 
PDF
Modern infrastructure as code with ansible PyTN
Joe Ferguson
 
PDF
Slim PHP when you don't need the kitchen sink
Joe Ferguson
 
PDF
Throwing Laravel into your Legacy App™
Joe Ferguson
 
PDF
DevSpace Conf 2017 - Making sense of the provisioning circus
Joe Ferguson
 
PDF
Release and-dependency-management memphis python
Joe Ferguson
 
PDF
Composer at Scale, Release and Dependency Management
Joe Ferguson
 
PDF
Put an end to regression with codeception testing
Joe Ferguson
 
PDF
Midwest PHP 2017 DevOps For Small team
Joe Ferguson
 
PDF
Console Apps: php artisan forthe:win
Joe Ferguson
 
PDF
Console Apps: php artisan forthe:win
Joe Ferguson
 
PDF
So You Just Inherited a $Legacy Application… NomadPHP July 2016
Joe Ferguson
 
PDF
So You Just Inherited a $Legacy Application...
Joe Ferguson
 
PDF
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Joe Ferguson
 
PDF
Madison PHP 2015 - DevOps For Small Teams
Joe Ferguson
 
PDF
ZendCon 2015 - DevOps for Small Teams
Joe Ferguson
 
PDF
ZendCon 2015 - Laravel Forge: Hello World to Hello Production
Joe Ferguson
 
PDF
Secure Form Processing and Protection - Devspace 2015
Joe Ferguson
 
PDF
Acceptance & Functional Testing with Codeception - Devspace 2015
Joe Ferguson
 
PDF
Continuous Integration: How I stopped guessing if that merge was bad
Joe Ferguson
 
Modern infrastructure as code with ansible cake fest 2021
Joe Ferguson
 
Modern infrastructure as code with ansible PyTN
Joe Ferguson
 
Slim PHP when you don't need the kitchen sink
Joe Ferguson
 
Throwing Laravel into your Legacy App™
Joe Ferguson
 
DevSpace Conf 2017 - Making sense of the provisioning circus
Joe Ferguson
 
Release and-dependency-management memphis python
Joe Ferguson
 
Composer at Scale, Release and Dependency Management
Joe Ferguson
 
Put an end to regression with codeception testing
Joe Ferguson
 
Midwest PHP 2017 DevOps For Small team
Joe Ferguson
 
Console Apps: php artisan forthe:win
Joe Ferguson
 
Console Apps: php artisan forthe:win
Joe Ferguson
 
So You Just Inherited a $Legacy Application… NomadPHP July 2016
Joe Ferguson
 
So You Just Inherited a $Legacy Application...
Joe Ferguson
 
Acceptance & Functional Testing with Codeception - SunshinePHP 2016
Joe Ferguson
 
Madison PHP 2015 - DevOps For Small Teams
Joe Ferguson
 
ZendCon 2015 - DevOps for Small Teams
Joe Ferguson
 
ZendCon 2015 - Laravel Forge: Hello World to Hello Production
Joe Ferguson
 
Secure Form Processing and Protection - Devspace 2015
Joe Ferguson
 
Acceptance & Functional Testing with Codeception - Devspace 2015
Joe Ferguson
 
Continuous Integration: How I stopped guessing if that merge was bad
Joe Ferguson
 

Recently uploaded (20)

PDF
July Patch Tuesday
Ivanti
 
PDF
Transforming Utility Networks: Large-scale Data Migrations with FME
Safe Software
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
PDF
The Rise of AI and IoT in Mobile App Tech.pdf
IMG Global Infotech
 
PPTX
AUTOMATION AND ROBOTICS IN PHARMA INDUSTRY.pptx
sameeraaabegumm
 
PDF
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
PDF
Biography of Daniel Podor.pdf
Daniel Podor
 
PDF
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
PDF
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
PPTX
Building Search Using OpenSearch: Limitations and Workarounds
Sease
 
PDF
How Startups Are Growing Faster with App Developers in Australia.pdf
India App Developer
 
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
PDF
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
PDF
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
PDF
What Makes Contify’s News API Stand Out: Key Features at a Glance
Contify
 
PDF
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 
July Patch Tuesday
Ivanti
 
Transforming Utility Networks: Large-scale Data Migrations with FME
Safe Software
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
The Rise of AI and IoT in Mobile App Tech.pdf
IMG Global Infotech
 
AUTOMATION AND ROBOTICS IN PHARMA INDUSTRY.pptx
sameeraaabegumm
 
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
Biography of Daniel Podor.pdf
Daniel Podor
 
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
Building Search Using OpenSearch: Limitations and Workarounds
Sease
 
How Startups Are Growing Faster with App Developers in Australia.pdf
India App Developer
 
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
What Makes Contify’s News API Stand Out: Key Features at a Glance
Contify
 
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 

Laravel 5 New Features

  • 1. Laravel 5 New Features Joe Ferguson
  • 2. Before we begin Have Virtualbox (virtualbox.org) Installed Have VirtualBox Extension Pack Installed Have Vagrant (vagrantup.com) Installed run: vagrant box add laravel/homestead
  • 4. Laravel 5 Directory App directory now "Your Application" / "Entry point to app” Laravel 4 Artisan Commands -> Console in App folder Web stuff in Http Controllers all have name space filters.php -> Broken out into separate classes/files. More focus on Service Providers -> Filter Service Providers No more global.php -> Use service providers Removed models directory. Can be just in app folder. PSR-4 default Don't like the app namespace? artisan app:name MyApplication
  • 5. Blade Changes Laravel 4 uses {{ to echo and {{{ To echo escaped Laravel 5 {{ and {{{ will echo escaped and {!! is used to echo raw Biggest impact is likely form helpers: {!! Form::open() !!}
  • 6. Commands Commands (app/Commands) - Message containing only info needed to do something Command Handler (app/Handlers/Commands) - Class that does something in response to a command Command Bus - Allows dispatch of commands, matches commands to handlers Self handling commands just need a handle() method on the command & implements SelfHandling
  • 7. Events Events (app/Events) Events have handlers (similar to Commands) Bind Events via appProvidersEventServiceProvider.php Events inform the system something happened VS demanding action from the system
  • 8. Form Requests Special class for validating and authorizing form submissions Each class has rules() (returns array) and authorize() (returns boolean) methods Benefit of rules & authorize being methods is you can perform logic Type Hinting your forms to the Form Request will automatically validate your forms If validation fails, errors will be available to the view and redirected back. This happens because the FormRequestServiceProvider listens for anything being resolved is instance of FormRequest and calls the validate method.
  • 9. Helpers view() - Get a View instance for the given view path action() - Generate a URL for a given controller action app_path() - Get the fully qualified path to the app directory asset() - Generate a URL for an asset. Routing – get(), delete(), put()
  • 10. Route Caching artisan route:cache Serializes your routes.php Benefits: Faster routing Drawback: Must run artisan route:clear on every routes.php change
  • 11. Middleware Implements decorator pattern. request -> does work -> returns object to next layer Laravel uses middleware for Encrypting/Decrypting cookies, Reading/Writing Sessions artisan make:middleware MyMiddleware (app/Http/Middleware) Middleware registered in app/Http/Kernel.php Can run before or after the request has been processed. Easiest example would be auth
  • 12. Controller Method Injection Can inject dependencies into methods, no longer via constructor Purpose is to help developers write cleaner code
  • 13. Changes to Illuminate Packages Form or HTML helpers no longer in Core, must be pulled in via composer. add "laravelcollective/html": "~5.0" to composer update config/app.php
  • 14. Elixir API for defining basic Gulp tasks for your app. Requires nodejs Put your sass/less files in resources/assets/sass|less Can trigger sass/less/phpunit/phpspec, combine stylesheets
  • 15. Socialite Easy to use social logins with oauth Supports Facebook, Twitter, Google, Github, and Bitbucket
  • 16. Contracts Set of interfaces that define the core services provided by the framework Depend on abstractions, not concrete dependencies. Write code that doesn't have to be aware of the laravel framework
  • 17. Upgrade from 4.2 to 5 Fresh install Laravel 5 Update Dependencies /Packages Namespace (somewhat optional for now) Migrate environment variables Move routes to app/Http/routes.php Move controllers to app/Http/Controllers (add this to classmap) Copy route bindings to boot() in app/Providers/RouteServiceProvider.php Add route facade to RouteServiceProvider.php to continue using Route facade CSRF is now global. Use middleware to disable if needed Move models to app/Models. Add app/Models to classmap in composer.json Update your user auth to use Laravel 5’s auth system Move commands to app/Console/Commands. Add app/Console/Commands to classmap in composer.json Move migrations to database/migrations, Database Seeds to database/seeds … and more!
  • 18. Upgrade from 4.2 to 5 http://laravel.com/docs/5.0/upgradeFresh install Laravel 5 Update Dependencies /Packages Namespace (somewhat optional for now) Migrate environment variables Move routes to app/Http/routes.php Move controllers to app/Http/Controllers (add this to classmap) Copy route bindings to boot() in app/Providers/RouteServiceProvider.php Add route facade to RouteServiceProvider.php to continue using Route facade CSRF is now global. Use middleware to disable if needed Move models to app/Models. Add app/Models to classmap in composer.json Update your user auth to use Laravel 5’s auth system Move commands to app/Console/Commands. Add app/Console/Commands to classmap in composer.json Move migrations to database/migrations, Database Seeds to database/seeds … and more!
  • 19. Homestead “Laravel Homestead is an official, pre-packaged Vagrant "box" that provides you a wonderful development environment without requiring you to install PHP, HHVM, a web server, and any other server software on your local machine. No more worrying about messing up your operating system! Vagrant boxes are completely disposable. If something goes wrong, you can destroy and re- create the box in minutes!”
  • 20. What’s in the box: • Ubuntu 14.04 • PHP 5.6 • HHVM • Nginx • MySQL • Postgres • Redis • NodeJS • Bower • Grunt • Gulp • Beanstalkd • Memcached • Laravel Envoy Fabric + HipChat Extension + more!
  • 21. Getting Homestead Install the box: vagrant box add laravel/homestead
  • 22. Getting Homestead If you have PHP installed locally: composer global require "laravel/homestead=~2.0" Make sure to place the ~/.composer/vendor/bin directory in your PATH so the homestead executable is found when you run the homestead command in your terminal.
  • 23. Homestead 2.0 Significant change over previous 1.x versions Uses homestead from your home folder Less vagrant stuff in your projects (if you don’t like that sort of thing)
  • 24. How I use Homestead https://github.com/svpernova09/HomesteadSkeleton Drop in Homestead files to project Each project has an isolated vagrant environment Easier to share dev environment settings