Check for matching values in two arrays with JavaScript
Learn how to find matching values between two arrays using JavaScript
Split the decimal from a number in JavaScript
How to get the decimal element from an integer using JavaScript.
Shuffle array items with JavaScript
How to shuffle array items with JavaScript.
Round a decimal number down with JavaScript
How to round a decimal number down with JavaScript
Round a decimal number up with JavaScript
How to round a decimal number up with JavaScript
Add a tax percentage to array of prices
Ways to add a percentage to array elements.
Find element in array and delete it
Find an array element and delete it with splice().
Remove an object element from an array
Removing an object element from an array is possible using the 'filter()' method.
Calculate the sum of array elements
Calculate the sum of array elements with the reduce() method.
How to add elements to and remove elements from an array
Add elements to the beginning and end of an array with the unshift and push methods. Remove them using the pop and shift methods.
Remove duplicate elements from array with loops
Removing duplicate elements from array with loops and the includes() method.
Remove duplicate elements from array with Set()
Removing matching array elements is easy with Set().
The CSS container property
The CSS container property allows responsive styling at a micro level.
CSS has()
Playing around with the CSS has() pseudo-class to see what it does.
Working with dates in vanilla JavaScript
Working with dates in JavaScript including today, year, date number, month number and day number.
JS Arrays in numerical order
Sorting array elements in numerical order with Javascript.
Calculate and display hours and minutes with JavaScript
This JavaScript snippet calculates and displays hours and minutes from a user's number input.