Currently browsing JavaScript DOM

Monday, May 16, 2022

tail.select takeover and update

I have been using the tail.select library on 200+ WordPress websites for more than 2 years. That number is growing,…

Monday, May 16, 2022

tail.select

HTML Select Fields as beautiful as never before tail.select is back: Create beautiful, functional and extensive (Multi) Select Fields with…

Monday, May 16, 2022

How I added a neat effect in 30 lines using IntersectionObserver

This is something I’ve always wanted to add to my theme, but I was afraid of the impact on the…

Tuesday, June 28, 2022

How to Get and Set Query Parameters From URL

Here are two ways to get (and set) query parameters from URL. I’ll add some real life examples in order…

Monday, May 16, 2022

How to Create a Price Range Slider Using Vanilla JavaScript

All JavaScript range sliders are hacks or workarounds. Because there’s no native HTML element for a range slider (only a…

Monday, May 16, 2022

How to Create a JavaScript Typewriter Using Vanilla JavaScript

This was done for a client, and I do not recommend it as it uses setTimeout(). Anything using setTimeout() or…

Monday, May 16, 2022

Drift Chat: Speed Up Your Page Loading Speed by 3-4 Seconds

Here’s a neat trick to speed up your initial page loading time when you are using Drift. If you use…

Friday, May 20, 2022

24-Hour Countdown with Progress Saving Using Vanilla JavaScript

Here’s an interesting JavaScript snippet allowing you to set a 24-hour countdown and save its progress, so that on the…

Monday, May 16, 2022

Random Imgur Images Using Vanilla JavaScript

I found this old code I used for an old forum a long time ago and I decided to bring…

Monday, June 13, 2022

How and why I added a circle following my mouse pointer

I’ve seen this behaviour on several Russian sites, and it looked really slick, especially when the movement was delayed compared…

Monday, May 16, 2022

Switching From JavaScript to PHP for Browser Detection and Avoiding Core Web Vitals Penalties

In the light of the recently introduced Core Web Vitals, I decided to save some script start-up speed and switch…

Friday, June 3, 2022

How to Change Page Title Using JavaScript

This JavaScript will modify the text of the browser tab when a visitor focuses or unfocuses the tab. You can…