Juan Diego Rodríguez (also known as Monknow) is a front-end developer from Venezuela who loves making beautiful websites with modern technologies but

JavaScript APIs You Don’t Know About

submited by
Style Pass
2022-09-21 20:30:34

Juan Diego Rodríguez (also known as Monknow) is a front-end developer from Venezuela who loves making beautiful websites with modern technologies but also … More about Juan Diego ↬

A couple of days ago, I revisited the awesome 2021 State of JS Survey. The state of JS is an online survey that collects data from developers around the world to see the most recent and upcoming trends in the JavaScript community. Among the data it collects, a section is dedicated to the native features JavaScript provides, listed by their usage and awareness. As you can imagine, among the most used features are popular ones like Optional chaining, Nullish coalescing, Websockets, and so on.

However, I wasn’t interested in the most used or known APIs. Instead, I was looking for the least known ones. I wanted to know which APIs we aren’t talking about enough, and among them, I found four pretty different APIs that are extremely useful:

This is a little-known web API that rates last fourth in awareness in the State of JS Survey. It lets you know when a user has left the page. To be precise, the API triggers an event whenever the page visibility status changes, either when the user minimizes or maximizes the window or switches the tab.

Leave a Comment