Set is an iterable object that holds a collection of unique values. An array is also an iterable object that holds a collection of values, but the values in an array do not have to be unique. We can use the
Set constructor to create a new
Set from an array, returning only the unique values of that array. How does this method of removing duplicates compare to an iterative loop approach? Let’s take a closer look at both options to find out.
Problem: We need only the unique values from a large array.
Well, a pretty solid solution…
Database schemas can get pretty gnarly and it can be difficult to visualize the relationships between your tables. This can cause some serious time delays and is often a source of frustration during the planning stages. Enter the ERD, or “Entity Relationship Diagram”. ERDs can help us design our schemas in a visual way, allowing us to see our tables and their relationships. This not only saves us time, but it also gives us an opportunity to experiment with our schema before it is implemented.
With GraphQL you can query a single endpoint and get back exactly the data you need. Nothing more, nothing less. Sounds nice right? It gets better! If you are currently consuming a regular ‘ol REST API and they also happen to have a GraphQL API available, you can massively reduce the amount of data being requested and speed up your application. I’m sure that the lower data usage would also be a welcome change, especially if you are developing for mobile.
Since recursion can be a difficult concept for some to grasp, I think we will start with one of the classic examples of recursion…
Being watched and analyzed while you attempt to solve a problem you have never seen before can be pretty intimidating. Especially when whether or not you land the job depends on it. In this Article we will take a look at one variant of a classic technical interview question. I will walk you though how I would approach it and the steps I would take to solve it.
We will be looking at an interview question that you are very likely to come across in your job search. The interviewer may not state the problem in exactly the same way…
In this article, we will create a simple form that takes one input, the user’s location, and changes the input box size so we don’t have any overflow.
In this article, we will create a simple form that takes one input, the user’s location, and changes the font size so we don’t have any overflow.
A pretty common theme in my articles is the proper way to use state and/or state hooks. Mutating state directly is a big no-no. If we mutate state without creating a new object, we can lose functionality and cause some strange behavior.
Looking to class things up with an analog clock? Well, you have come to the right place. In this article, we will look at one way to build a simple analog clock in React using functional components. As a bonus, we will also create a digital clock for those with varying degrees of dyscalculia.
Let’s start by building a functional component in a new file called Clock.js.
Who doesn’t love a nice live/instant search feature? They save the user the hassle of typing out the full query and they can be especially useful when trying to find something in a list that has already been populated.
In this article, we will set up a live search for our friends list so that the user can find a specific friend more easily.