I think many of us who spend a lot of time working on front end solutions in have been integrating functional techniques into our day to day. I started to do it mostly on faith — a “if there’s smoke there must be fire” kind of thing. JavaScript programming At first, I appreciated being able to cut down on a bit of boilerplate code. I very rarely create counter variables anymore, for instance. Instead of a “ ” I use a “ ”. And actually, the whole “for (let i=…)” construct is often used to filter out objects from a collection or some kind of of transformation on objects in a collection. As a result, I hardly even use array.forEach, I use , and much more. for (let i = 0; i <100; i++) array.forEach( () =>) filter map reduce I love cutting down on the boilerplate and that is indeed its own reward. However, I have discovered, unexpectedly, that I my own code more than I ever did before. In fact, when I look back at code I wrote even a year ago, I see it as almost crippled and feeble. I’m exaggerating a bit, but you get my point. trust Immutability provides the basis for this trust. If everything you create is created just once and never changes, the risk of unintended side effects is greatly reduced. In JS, we can’t eliminate that kind of thing, but it cuts down on the risk. It’s very comforting. Richard Eng (not exactly a fan of JavaScript) wrote this post about how much he loves SmallTalk ( ). After reading it, I realized how much this newfound enjoyment from FP has affected me. For instance, I was looking at this morning and thinking — “he should really be using for most of those variables”. I was looking at someone else’s interesting multi-player game that had a bit of code plucking a player object out of a collection and thinking — “he should really use reduce for that and cut down 15 lines of code and 2 loops into a single line and get rid of those otherwise useless looping variables”. Smalltalk ruined my life — The cost of a happy addiction the code behind this reddit post const If you’re looking for some reason to pick up some functional programming habits, consider “trust.” It’s a real comfort and has added a bit of joy to this developer’s programming life :). </end> is how hackers start their afternoons. We’re a part of the family. We are now and happy to opportunities. Hacker Noon @AMI accepting submissions discuss advertising &sponsorship To learn more, , , or simply, read our about page like/message us on Facebook tweet/DM @HackerNoon. If you enjoyed this story, we recommend reading our and . Until next time, don’t take the realities of the world for granted! latest tech stories trending tech stories