Archive for the ‘vanilla javascript’ Category

A Beginner’s Guide to JavaScript Variables and Datatypes

Posted on: No Comments
So you've decided to learn JavaScript, the programming language of the web. If it seems like a daunting journey ahead and you don't know where to start, here's a little secret: it doesn't take any special skill to learn how to program, and everyone st...

Quick Tip: Use Bootstrap Components without jQuery

Posted on: No Comments
Do you use Bootstrap's JavaScript components? Do you like Vanilla JavaScript? Then you might be interested in the Native JavaScript for Bootstrap project, which aims to remove the jQuery dependency required by the components by porting them to plain J...

Building a JavaScript 3D Minecraft Editor

Posted on: No Comments
I've always wanted to build a 3D game. I've just never had the time and energy to learn the intricacies of 3D programming. Then I discovered I didn't need to... While tinkering one day, I got to thinking that maybe I could simulate a 3D environment usi...

Quick Tip: How to Style Google Custom Search Manually

Posted on: No Comments
Website owners very often decide on using Google's Custom Search Engine (GCSE) for searching through their content instead of using built-in and/or custom search functionality. The reason is simple - it's much less work, and most often it does the tric...

Saved from Callback Hell

Posted on: No Comments
Callback hell is real. Often developers see callbacks as pure evil, even to the point of avoiding them. JavaScriptʼs flexibility does not help at all with this. From the surface, it seems callbacks are the perfect foot gun, so it is best to replace th...

Quick Tip: Add or Remove a CSS Class with Vanilla JavaScript

Posted on: No Comments
Sometimes you need to add or remove a CSS class with JavaScript, and you don't want to include an entire library like jQuery to do it. This is useful in situations when you want your page elements to change in response to user actions. Example uses i...

Quick Tip: How to Declare Variables in Javascript

Posted on: No Comments
When learning JavaScript one of the basics is to understand how to use variables. Variables are containers for values of all possible types, e.g. number, string or array (see data types). Every variable gets a name that can later be used inside your ap...

Pragmatic Uses of Monkey Patching in JavaScript

Posted on: No Comments
Have you ever worked with third-party code that worked well except for one little thing that drove you nuts? Why did the creator forget to remove those pesky console logs? Wouldn't it be great if that API call could do just one more thing? If so then y...

Quick Tip: Get URL Parameters with JavaScript

Posted on: No Comments
So you want to get a parameter from a URL? URL parameters (also called query string parameters or URL variables) can have lots of useful data including product info, user preferences, link referrals, and more. Let's get started! Getting URL Parameters ...

Create a Music Jam Station with Vanilla JavaScript

Posted on: No Comments
The HTML5 audio player has given rise to some new and exciting possibilities, especially when it comes to music related web applications. I hope to introduce you to some of these possibilities by walking you through how I created this jam station. Th...