var please = require('share');
console.log('thank you');

NEW !!!

Friday, 30 April, 2021 UTC

Image Optimization Strategies Compared (Sponsored)

We all know the stats. Slower website performance is strongly linked to higher abandon rates and lower conversions. What you may not know is that the main culprit is bloated web page payloads, bringing down our otherwise performant web pages via images. ... more

Monday, 26 April, 2021 UTC

Regular Expression Match Groups

Regular expressions are incredibly powerful but can be difficult to maintain. They’re a skill you learn on the job and, when the suits walk by, make you look incredibly smart if you have a few up on your screen. How can we solve the maintainability problem? ... more

Tuesday, 20 April, 2021 UTC


Navigating and managing data structures is a really important skill for every level of engineer to have and improve upon. Over the years, the JavaScript language has continued to provide more methods for managing data structures, from Object.keys to ... more

Monday, 19 April, 2021 UTC

CSS Smooth Scroll

Improving the user experience of web applications has always been a priority of mine. I always come back to the same though I’ve had for 20 years: “users expect a web app to work — let’s make the app a joy to use.” Over the years we’ve employed JavaScript ... more

Tuesday, 13 April, 2021 UTC


Formatting numbers on the client side is an important task, especially when you consider how much raw API usage is in play these days. What’s also important is ensuring those numbers are meaningful to users, no matter where they are in the world, especially ... more

Thursday, 8 April, 2021 UTC

Detect CSS Overflow Elements

Every once in a while you encounter a CSS annoyance that takes some cleverness to discover. One such case rears its ugly head in unwanted and unexpected scrollbars. When I see unwanted scrollbars, I usually open developer tools, click the element inspector, ... more

Tuesday, 23 March, 2021 UTC

VS Code node:console Fix

I’ve been using Microsoft’s Visual Studio Code text editor for years with great success. The app has always been stable, flexible, and the best compliment I can give it: an afterthought. Recently, however, every time I added a console.log to a JavaScript ... more

Monday, 22 March, 2021 UTC

Use Logpoints!

There’s sometimes a tribal attitude about how web developers should be debugging their code and solving problems. There’s the console.log loyalists, then there’s the debugger/breakpoint maximalists. I worked on the Firefox DevTools debugger for years ... more

Thursday, 11 March, 2021 UTC

Insert Cursor at Any Position at Command Line

As much as I enjoy writing lengthy pieces of JavaScript APIs, techniques, and other tech brilliance, I very much enjoy providing people quick tips to make their daily dev lives better. This is one such post. Oftentimes I’m working with long command line ... more

Thursday, 4 March, 2021 UTC

React authentication, simplified

Authentication is one of those things that just always seems to take a lot more effort than we want it to. To set up auth, you have to re-research topics you haven’t thought about since the last time you did authentication, and the fast-paced nature ... more

Friday, 12 February, 2021 UTC

How to Install a NPM Module from GitHub Branch

In my journey to work more quickly with a project containing loads of dependencies, I’ve come across a few techniques I’ve not needed to use before. I previously wrote about How to Push to a Git Remote Branch of a Different Name — this time we’ll talk ... more

Monday, 8 February, 2021 UTC

Fix “no such file or directory, scandir”

After 15+ years in the web development industry, and seeing the landscape of tooling change, I’ve really lost patience with tooling errors. Like…Old Man Walsh just wants yarn install to work so he can get on with his work day. One recent error I ran ... more

Monday, 25 January, 2021 UTC

JavaScript Wake Lock API

An enjoyable web apps rely on engineers implementing the APIs that cover all of the small things. Those small things sometimes improve performance, usability, accessibility, and the app’s relationship with its host system. The Wake Lock API is the latter ... more

Tuesday, 29 December, 2020 UTC

Goals For 2021

Every year I write a blog post about my goals for the year but I won’t pretend this year’s post is the same. I mean how the hell do I create realistic goals knowing what 2020 was and what 2021 inherits?! Pandemic, drastic political churn, social unrest…and ... more

Wednesday, 23 December, 2020 UTC

Return a Default Value with Promises Using catch

Last week I tweeted all of you looking for your best JavaScript Array and Promise tricks, and as always, it didn’t disappoint — I learned quite a bit! Today’s JavaScript Promise trick is brought to you by Claudio Semeraro: how to use catch to set a default ... more

Tuesday, 22 December, 2020 UTC

Break a forEach Loop with JavaScript

I’ve written a number of blog posts about JavaScript tricks: Promise tricks, type conversion tricks, spread tricks, and a host of other JavaScript tricks. I recently ran into another JavaScript trick that blew my mind: how to break a forEach loop, shared ... more

Monday, 21 December, 2020 UTC

Sharpen Your JavaScript Skills with Pluralsight (Sponsored)

JavaScript recently turned 25 years old, and while it started by dominating over the client side world, this beautiful programming language is well on its way to taking over the server side. JavaScript isn’t just thriving — it’s evolving with new syntax ... more

Monday, 14 December, 2020 UTC


Knowing what input type you’ve received is hugely important in JavaScript, which is a big reason for Flow and TypeScript’s rise. One such case where it’s useful to know what an object represents is if the input is a string or a React element. To detect ... more

Monday, 30 November, 2020 UTC

10 Amazing Media Tricks Made Possibly by Cloudinary (Sponsored)

Cloudinary is my go-to place for transforming and optimizing media before delivery. By simply modifying the URL of an image or video, you can customize its size, presentation, Instagram-like filtering, and various other aspects. I previously posted about ... more

Monday, 23 November, 2020 UTC

Detect Generator Functions with JavaScript

In the current JavaScript climate of new syntaxes, features, and using loads of external libraries, it seems harder than ever to be sure what your functions are being given or even what the data represents. Of course, we’ve come up with Flow and TypeScript ... more

Friday, 13 November, 2020 UTC

Node isConnected

Every so often I discover a property in JavaScript objects that I didn’t know existed, oftentimes using another trick to accomplish the same functionality. One such property I just learned about was isConnected , a node property that attached to a context ... more

Tuesday, 3 November, 2020 UTC

Limit Promise Concurrency with pool

Methods like Promise.all , Promise.allSettled , Promise.race , and the rest are really excellent for managing multiple Promises, allowing for our apps to embrace async and performance. There are times, however, that limiting the number of concurrent ... more

Wednesday, 28 October, 2020 UTC

How Hacker News Crushed David Walsh Blog

Earlier this month, David’s heartfelt posting about leaving Mozilla made the front page of Hacker News. Traffic increased by 800% to his already-busy website, which slowed and eventually failed under the pressure. Request Metrics monitors performance ... more

Tuesday, 20 October, 2020 UTC

cookieStore: Async Cookie API

One pattern in the JavaScript API world that web development veterans will notice is that we’ve been creating new methods to accomplish what older, grosser APIs once achieved. XMLHttpRequest became the fetch API, some APIs like Battery became async, ... more

Friday, 16 October, 2020 UTC

How to Conditionally Add Attributes to Objects

JavaScript is full of tricks that you don’t know you want until you … want … them. Or maybe just until you see them. One trick I recently realized was conditionally adding attributes to React elements. Of course this trick essentially boils down to conditionally ... more

Monday, 5 October, 2020 UTC

How to Detect When a Sticky Element Gets Pinned

The need for position: sticky was around for years before it was implemented natively, and I can boast that I implemented it with JavaScript and scroll events for ages. Eventually we got position: sticky , and it works well from a visual perspective, ... more

Thursday, 24 September, 2020 UTC

How to Create an Async Function

One thing I love about JavaScript is that there are many ways to accomplish the same task, one such example being creating functions. There are several patterns for functions; one of the last you see used is the new Function method: /* new Function(arg1, ... more

Monday, 21 September, 2020 UTC

Vital Web Performance

I hate slow websites. They are annoying to use and frustrating to work on. But what does it mean to be “slow”? It used to be waiting for document load. Then waiting for page ready. But with so many asynchronous patterns in use today, how do we even define ... more

Monday, 14 September, 2020 UTC

5 Awesome JavaScript Promise Tricks

The Promise API changed the game in JavaScript. We went from abusing setTimeout s and settling for synchronous operations to doing everything possible to leverage this new async API. Let’s check out a handful of awesome Promise API tricks! Cancel a fetch ... more

Thursday, 10 September, 2020 UTC

Logical Assignment Operators

I love JavaScript, it’s my favorite programming language, but I love dipping into other languages because they offer a new perspective on coding paradigms. There’ve been syntax additions to JavaScript that I’ve seen I found interesting (think ?? in optional ... more