What’s New This Week at CodeReviewVideos – 30th December 2016

I hope you’ve had a nice Christmas week. I remember carving the turkey on Christmas day somewhat concerned there might not be enough. And yet, only yesterday did we finish the last of the left overs. Madness.

Over the course of the last week you may have read (via Twitter) a discussion around “side projects” and should developers be doing them in their free time over Christmas. I’ll start by sharing my opinion on this, but I’d love to hear yours:

For me, side projects are amongst the most important things a developer can be doing with their free time. Now, I’m not talking about sacrificing spending time with your family to instead be eyeballs-in-front-of-monitor (Lord knows, we do enough of that all year anyway). I mean if you’re going to sit down and write a bit of code, it might as well have some structure to it.

One of the things that I frequently hear from others developers is that we don’t get the opportunity – at work – to play with interesting / new technology. For example:

“I want to learn Redis, but my boss won’t let me.”

Controversial – I agree with your boss! 🙂

I mean I agree with the underlying reason: no, you are not hacking Redis into the production, money-making stack that runs the companies business to scratch your technical itch.

And that’s fine. There’s a way to play with Redis without any approval from your boss:

Use it in a side project!

Side projects don’t need to change the world. They don’t need to become self sustaining businesses in their own right. They have always worked best for me when they satisfy some personal demand I have that might also just happen to allow me to play with some new tech – Elasticsearch, Ansible, Graylog, etc.

Then, once you’ve played with your new tech (e.g. Redis), and used it in a real (side) project, not only will you have something new to stick on your CV, but you can also talk more authoritatively with your boss / colleagues / significant other about how awesome {shiny_new_tech} is, and how it might improve said current money making business system even further.

And hey, if your side project does transform into something money making, maybe one day in the not too distant future you will have employees of your own asking to shoehorn Rails into your PHP code, so they too can scratch their own itch 🙂

This Week in Videos

Throughout this week there have been three new videos.

First up, we looked at how we might add a spinner to our React / Redux application:

https://codereviewvideos.com/course/react-redux-and-redux-saga-with-symfony-3/video/showing-spinning-icons-because-why-not

Whilst on the surface this seems really simple, what’s cool here is how that spinning icon is displayed depending on a current value in our Redux-managed state. The idea here is to keep our application’s code sane and manageable as we grow.

This implementation is fairly naive. As our application grows – think: maybe we add a Registration flow using Stripe – then we’re going to hit a bug in the way our spinner works on the back end. Thinking about this, we then move on to a better implementation:

https://codereviewvideos.com/course/react-redux-and-redux-saga-with-symfony-3/video/more-robust-request-tracking

This is nice and all, and maybe good enough, but from my own personal real world experience, we could still hit on an issue whereby our spinner seems to show / hide unexpectedly. The problem we have now is that to track multiple requests (e.g. one to Stripe, another to our API, all in the same form submission), we need a more involved reducer implementation. And whilst we could have a hack at it, instead it makes sense to write a tested implementation.

https://codereviewvideos.com/course/react-redux-and-redux-saga-with-symfony-3/video/getting-started-testing-with-jest

As if we haven’t covered enough new stuff in this series (what with React, Redux, Redux Saga, React Router, Yarn, Bootstrap 4… the list goes on), we’re going to start testing all our code using Facebook’s JavaScript testing framework – Jest.

To me, this makes sense as our entire stack is Facebook centric already. We might as well embrace the tooling they use. After all, if it’s good enough for the third biggest web site in the world then it’s good enough for me.

I’ll finish up here by covering one last point:

In my quest to find out how popular Facebook is for the purposes of this post, I Google’d “alexa”. In the olden days, the defacto result for Alexa would have always been the site I linked to earlier. Now Alexa is an Amazon product which occupies the top two search engine results. Alexa – the company – is owned by Amazon, and comes third. I feel old.

And with that, I would like to wish you all a very Happy New Year, and a prosperous and successful 2017.

Chris

Published by

Code Review

CodeReviewVideos is a video training site helping software developers learn Symfony faster and easier.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.