Curing the Common Loop

Adam Wathan (04.May.2017 at 09:15, 1 hr )
Talk at PHP Unicorn Conference (Online) (English - UK)

Rating: 5 of 5

Trying to understand a complex function full of nested loops and conditionals is like trying to read a "choose your own adventure" book from front to back.

In this whirlwind tour of programming with collection pipelines, you'll learn how to use functional programming ideas to break down complex code and abstract hidden duplication behind expressive higher order functions.

By leveraging the power of Laravel's Collection class, we'll refactor ugly, complicated spaghetti into a series of simple, elegant transformations, free of loops, complex conditionals, and temporary variables.

Never write another loop again.

Who are you?

Claim talk

Talk claims have been moved to the new site.

Please login to the new site to claim your talk

Comments closed.


Rating: 4 of 5

04.May.2017 at 10:08 by David Carr (39 comments) via Web2 LIVE

a really interesting talk I love how the problems were explained them to the solution but felt the pace was really fast paced making it hard to keep up with the content being discussed.

once the live coding started the pace was much better, the explanation of what's happening and why was fantastic.

I really enjoyed this talk and look will be looking at functional programming.

Rating: 5 of 5

04.May.2017 at 11:07 by Ellie Strejlau (3 comments) via Web2 LIVE

I want to use this pattern everywhere now.

Rating: 5 of 5

05.May.2017 at 06:49 by Freek Van der Herten (66 comments) via Web2 LIVE

Even though you were in my case preaching to the choir, it was still fun to see the talk (again).

Rating: 5 of 5

09.May.2017 at 01:51 by Gene Surov (4 comments) via Web2 LIVE

I had a strong argument with my colleague during this talk. We stated that loops are better readable in their classic form while I more agreed with Adam here. Functional programming is really cool and simple to use. This talk was very simple to understand and contained a lot of examples. Thank you, Adam!

© 2019