Article
Regular expressions are on of the most powerful tools in a developer's toolkit. But let's be honest, regex kind of sucks to write. Not only is it hard to write, but it's also hard to read and debug too. So how can we make it easier to use? In its...
Scott Robinson
Byte
Let's talk about extracting names from email addresses using JavaScript. This can be useful when you're dealing with bulk data and need to personalize your communication. For instance, you might want to send out a mass email to your users but address each one by their name. Let's see how...
Let's explore a fundamental task in web development: refreshing a web page. But we're not talking about the classic F5 or CTRL+R here. We're instead going to be using JavaScript and jQuery to programmatically refresh a page. This is a handy trick for when you need a "hard&...
If you've been working with JavaScript, you've probably come across the term export default and wondered what it is or how it works. This Byte is meant for developers with a basic understanding of JavaScript, who are looking to deepen their knowledge of the language's intricacies. We'll be taking a...
In this Byte you'll learn a bit about the importance of CSS classes and how to manipulate them using both vanilla JavaScript and jQuery. By the end, you'll be able to dynamically alter the appearance and behavior of your web elements with ease. Let's get started! CSS Classes As you...
If you've been working with React, you would know that it's a powerful JavaScript library for building user interfaces. But sometimes, you need to go beyond the basic click and change events. This is where event listeners come into play. This Byte is ideal for developers who are familiar with...
When dealing with real-time, interactive, or dynamic applications, you may need to run a function every N seconds in TypeScript. In this Byte, we'll go over exactly how to do that. Why Use Time-Interval Function Calls? There are a lot of different scenarios where you might want to execute a...
Ever wondered how to manage sensitive data like API keys, database credentials or configuration settings in your Node.js applications? The answer lies with environment variables. This Byte will give a brief intro to environment variables, why they are important, and then we'll explore how to read them in Node....
In programming, we often need to deal with dates and times, which can be represented in a few different ways, like an object (via Date), a string (i.e. "2023-10-04T00:00:00.000Z"), or a timestamp (i.e. 1696377600000). In this Byte, we'll explore how to convert a...
© 2013-2024 Stack Abuse. All rights reserved.