Laravel 6.5 Is Now Available

Sami Maxhuni
Nov 8 · 1 min read

The Laravel team released v6.5 this week with a new remember function added to the LazyCollection. Also, this release includes a few new string helpers, custom unless blade conditions, and a few new query builder methods.

First, a new LazyCollection::remember() method which remembers any enumerated values and will not pull them from source when enumerated again. Here’s an example from the pull request:

Here’s an example from the PR’s tests, which might be a little simpler to understand:

Next, two new Str methods were added: afterLast() and beforeLast():

Next, the query builder now has existsOr and doesntExistOr methods, which allow you to define a callback when the condition is false:

Last, new unless conditions are added to custom Blade if directives. For example, a custom env example from the Blade documentation allows you to use this syntax in Blade:

Now you can additionally use the “unless” variant of this condition to avoid weird if/else scenarios:

You can see the full list of new features and updates below, and the whole diff between 6.4.1 and 6.5.0 on GitHub. The full release notes for Laravel 6.0 are available in the GitHub v6 changelog

Sami Maxhuni

Written by

Back End Developer — Laracodes

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade