Category: nilsonj

Sharing React Components Easily with Bit

This is the age of components. Frameworks built for UI components, such as React, enable us to split our UI into individual, reusable pieces that can be worked with in isolation. In many ways, React components are not that different from other encapsulated code functionalities. They can get defined inputs (usually “p...

Writing Server-rendered React Apps with Next.js

The dust has settled a bit as far as the JavaScript front-end ecosystem is considered. React has arguably the biggest mindshare at this point, but has a lot of bells and whistles you need to get comfortable with. Vue offers a considerably simpler alternative. And then there’s Angular/Ember which, while still popular,...

To Redux or Not: the Art of Structuring State in React Apps

One common trend I find among most Redux developers is a hatred towards setState(). A lot of us (yes, I’ve fallen into this trap many times before) flinch at the sight of setState() and try to keep all the data in our Redux store. But, as the complexity of your application grows, this poses several challenges. In...

A Guide to Testing React Components

React is a framework that has made headway within the JavaScript developer community. React has a powerful composition framework for designing components. React components are bits of reusable code you can wield in your web application. React components are not tightly coupled from the DOM, but how easy are they to uni...

Dealing with Asynchronous APIs in Server-rendered React

If you’ve ever made a basic React app page, it probably suffered from poor SEO and performance issues on slower devices. You can add back traditional server-side rendering of web pages, typically with NodeJS, but this isn’t a straightforward process, especially with asynchronous APIs. The two main benefits ...

Async Operations in React Redux Applications

This post was originally posted at Codebrahma. JavaScript is a single-threaded programming language. That is, when you have code something like this …… the second line doesn’t get executed till the first one gets completed. Mostly this won’t be a problem, since millions of calculations are performed b...

How to Build a React App that Works with a Rails 5.1 API

React + Ruby on Rails = 🔥 React has taken the frontend development world by storm. It’s an excellent JavaScript library for building user interfaces. And it’s great in combination with Ruby on Rails. You can use Rails on the back end with React on the front end in various ways. In this hands-on tuto...

Getting Started with React: A Beginner’s Guide

In this guide, I’ll show you the fundamental concepts of React by taking you through a practical, step-by-step tutorial on how to create a simple Message App using React. I’ll assume you have no previous knowledge of React. However, you’ll need at least to be familiar with modern JavaScript and NodeJS...

Exploring New Features in React 16

In this post, we’re going to learn how to create a music player using some of the new features in React 16. In implementing this music player, we’re going to learn about some of the changes in React 16. There are quite a few changes, so we won’t cover all of them, but we’ll cover the ones that are impor...

Learning JavaScript: 9 Common Mistakes That Are Holding You Back

A lot of people try to learn JavaScript and then give up. Then they tell themselves things like, “JavaScript is too confusing,” or worse, “Maybe I’m not cut out for web development.” The sad part? There was no need to give up. All that was needed was a different learning approach. In this ...