React Router is the standard for client-side routing in a React application. According to their documentation,
“React Router is a collection of navigational components that compose declaratively with your application.”
In this article, we will go through some of the main components of React Router and set up routing for a basic web application. For beginners, I hope this can help you to use React Router in your app. For experienced users, I hope this can be a nice refresher.
We will be using a React application created from create-react-app in our example below. …
Next.js is a React framework that enables a hybrid of server-side rendering and generating static pages for React applications. There are many benefits of using Next.js over the traditional React application, including better performance and SEO. If you are new to Next.js, have a look at the article below to get an overview of the framework.
In this article, we will be taking a look at routing in a Next.js app. This will include looking in the pages directory, how to handle dynamic routes, and understanding the Link component and useRouter hook.
The easiest way to get started with a Next.js app is to run the following command. …
I have been exploring different animation libraries recently and have come to like framer motion for my React apps. Framer Motion is described as a production-ready React animation and gesture library. Check out their website below to see some of the things you can do.
While building a web page the other day, I wanted to add an animation to an element, but I was having some trouble with the timing of it.
The problem was that the animation was happening when the component mounts upon page load. Doesn’t sound like a big deal, right? However, since the element was lower on the page, the animation was happening before I scroll down to see it. I needed to find a way to have the animation start when the element comes into the screen view. …
Since learning React, I have been using create-react-app for all of my personal projects. I love how easy it is to set up a boilerplate app and get to coding right away. Recently I had the urge to take my React skills to the next level, and that is when I came across Next.js.
According to Wikipedia, Next.js is an open-source React front-end development web framework that enables functionality such as server-side rendering and generating static websites for React-based web applications.
There are many things that you can do with chroma.js, including:
Learning to code as a self-taught developer takes time and commitment. Over the New Years' holiday, I was away from my computer for a few days and it got me thinking about other ways I can continue to learn about programming without actually writing code. Here are 4 ways that you can continue to grow as a developer even if you are away from your computer.
YouTube has been one of the biggest tools that have helped me to learn software development.
While there are many tutorial videos out there where you code along with the instructor, there are also many videos that are lifestyle based, motivational, or great to just watch casually without coding along. If I am thinking to start a project using new technology, I go to YouTube to look up a crash course or short tutorial to get an overview of the subject. …
According to Wikipedia, a priority queue is an abstract data type similar to a regular queue or stack data structure in which each element additionally has a “priority” associated with it. What does this mean? …
In this article, we will be taking a look at another type of data structure, Binary Heaps. If you are not familiar with trees, I recommend checking out the article below first.
A binary heap is a type of binary tree that has additional rules. To quickly review; a binary tree is a data structure that consists of nodes with a parent and child relationship. Each parent node can have at most two child nodes. In a binary heap, there are two additional rules:
In this article, we will be introduced to tree traversal. If you missed the last part of the series where we learned about trees, binary trees, and binary search trees, be sure to check out the article below first.
Tree traversal is visiting every node once in a tree. Compared to a list, array, stack, or queue where there is only one linear path to visit all nodes, a tree does not have a specific order in which you can accomplish this. There are two approaches when it comes to tree traversal: