October 2022

Using Font Awesome with React

Using Font Awesome with React

  • October 22, 2022

Font Awesome is a great resource to use various types of icons in your project including well-known social media icons and a lot more. It can be used with any front-end library. In this post, we are going to be using Font Awesome with React. Set up The first step...

How to write comments in React (JSX)?

How to write comments in React (JSX)?

  • October 15, 2022

I was recently trying to comment out some logic inside my JSX to add context about what a potentially complex logic. I then realized that comments in JSX are weird. So, how to write comments in React (JSX)? You cannot use HTML comments because they are parsed as DOM nodes:...

How to write more readable JavaScript conditionals

How to write more readable JavaScript conditionals

  • October 4, 2022

One of the practices of clean code is to make it more readable. And a fairly common use case in code bases is conditionals. I recently came across a way of writing more readable JavaScript conditionals and thought of sharing it with everyone. Consider the following conditional: The mind takes...