What’s New in Laravel 5.1

0
Language

Level

Beginner

Access

Paid

Certificate

Paid

Laravel 5.1 includes a variety of welcomed new features. Everything from broadcasting events, to massively improved testing facilities, to LTS support. As always, Laravel is setting the curve with this new release. Let’s breeze through the new features that you’ll be enjoying.

Add your review

Adopting PSR-2

Upon installing Laravel 5.1, the first thing you’ll notice is that the style guide is a bit different. Laravel now adopts the PSR-2 coding standard. If you’re not familiar, this is nothing more than a set of style guidelines for writing code.

Injecting Services With Blade

Inspired by ASP.NET MVC 6, you may now inject services directly into your views. While it’s not appropriate for everything, there are a number of situations where this technique will prove to be quite useful. Let me show you.

Elixir Improvements

In addition to a series of optimizations and consistency improvements, in Laravel 5.1, Elixir includes EcmaScript 6 compilation right out of the box, using the excellent Babel compiler.

Better Testing Facilities

If you worked through the Intuitive Integration Testing series, you’ll feel right at home in 5.1. Most of that API is now part of the base install. This means, you’ll be writing incredibly readable integration tests in no time.

Model Factories

Whether for database seeding or general testing, you’re going to love model factories in Laravel 5.1. A single line of code can give you a huge amount of convenience and power.

Artisan Signatures

In the past, defining arguments and options for an Artisan command was – to be frank – a big pain. For options, you needed to create a method that returned an array of arrays, where each one contained a sequence of values. It was up to you to memorize all of this. Thankfully, in Laravel 5.1, it’s infinitely easier. In fact, it’s as easy as defining a route.

Directory Changes

You’ll find that two directory names have been changed. “Commands” is now “Jobs”, and “Handlers” is now “Listeners.” Don’t worry

these changes won’t break your code. They’re backward compatible.

Documentation and LTS

We don’t require a code editor for this one. For Laravel 5.1, the documentation has been massively improved – with Taylor Otwell going over each and every page. Even better, we now have excellent search at our fingertips.

Middleware Parameters

We’ve already reviewed middleware parameters at Laracasts, so this episode will serve as a quick, crash-course overview.

Named Route Groups

This next one is by no means a big feature, but it might prove useful in some situations. You may now apply a prefix to your named routes. I’ll show you how.

Login Throttling

Login throttling in Laravel 5.1 is a breeze! In this lesson, we’ll review the basic concept, the implementation, and finally the underlying source code to make it possible.

Push Events to the Client

You know how to fire an event with Laravel, but what about when you want that event to travel all the way to the client-side? How the heck do we do that?

ACL in Laravel: Part 1

Laravel 5.1 is the first release to offer ACL functionality straight out of the box. Let me show you how laughably simple it is to work with!

ACL in Laravel: Part 2 (Policy Objects)

Let’s continue with our review of Laravel’s ACL capabilities, by reviewing policy objects.

ACL in Laravel: Part 3 (Behind the Scenes)

Before we move on to learning how roles fit into this workflow, let’s take some time to peek behind the scenes. This way, if you’re curious, you’ll know exactly how all the bits and pieces fit together.

ACL in Laravel: Roles and Permissions

For some projects, you may find that you require greater flexibility. Consider a CMS like WordPress, where users may be assigned roles, each which has its own set of permissions. How can we make that work?

User Reviews

0.0 out of 5
0
0
0
0
0
Write a review

There are no reviews yet.

Be the first to review “What’s New in Laravel 5.1”

×

    Your Email (required)

    Report this page
    What’s New in Laravel 5.1
    What’s New in Laravel 5.1
    LiveTalent.org
    Logo