Tips & Tutorials – Javascript

Set & Get Data Attributes In Javascript (Simple Examples)

Welcome to a quick tutorial on how to set and get data attributes in Javascript. Want to insert your own custom property or data into HTML elements? To set data attributes in HTML, we define data-KEY=”VALUE” in the start tag. For example, <div data-color=”red”> We can set data attributes in Javascript using the dataset property. …

Set & Get Data Attributes In Javascript (Simple Examples) Read More »

Javascript Loops & Iterations Cheat Sheet (Simple Examples)

Welcome to a beginner’s tutorial on Javascript loops and iterations. Want to loop through arrays and objects, or do things repetitively? The common mechanisms to loop and iterate in Javascript are: For – for (let i=0; i<10; i++) { … } For-In – for (let KEY in OBJECT/ARRAY/STRING) { … } For-Of – for (let VALUE …

Javascript Loops & Iterations Cheat Sheet (Simple Examples) Read More »

Javascript Appointment Scheduler Web App (Free Download)

Welcome to a tutorial on how to create an appointment scheduler web app with pure Javascript. Yep, there are a lot of “appointment schedulers” on the Internet. So here is a slightly different one, an offline-capable and installable web app – Read on! ⓘ I have included a zip file with all the source code …

Javascript Appointment Scheduler Web App (Free Download) Read More »

Simple Javascript Student Grading (Free Download)

Welcome to a tutorial on how to create a simple student grading page in Javascript. Creating your own grading system, or got one of these as a boring assignment? Well, a student grading page isn’t too difficult to deal with. Read on! ⓘ I have included a zip file with all the source code at …

Simple Javascript Student Grading (Free Download) Read More »

Javascript Library Management System (Free Download)

Welcome to a tutorial on how to create a simple library management system using Javascript. Yes, you read that right. This example does not involve any server-side scripts at all, and will showcase how we can use modern Javascript to build an offline system – Read on! ⓘ I have included a zip file with …

Javascript Library Management System (Free Download) Read More »

Javascript Customer Queue System (Free Download)

Welcome to a tutorial on how to create a simple customer queue system using Javascript. Yes, this is a web-based customer queue number system. But this is not a “traditional” one, this is a “leveled up” web app that works offline. Read on! ⓘ I have included a zip file with all the source code …

Javascript Customer Queue System (Free Download) Read More »

How To Move & Copy Files In NodeJS (Simple Examples)

Welcome to a tutorial on how to move and copy files in NodeJS. Need to back up some files in NodeJS? Move some old files to another folder? To copy a file in NodeJS – require(“fs”).copyFileSync(“SOURCE”, “TARGET”) To move a file in NodeJS – require(“fs”).renameSync(“SOURCE”, “TARGET”) That covers the quick basics, but read on if …

How To Move & Copy Files In NodeJS (Simple Examples) Read More »

Very Simple Collapsible List (Pure HTML CSS JS )

Welcome to a quick tutorial on how to create a collapsible list with HTML, CSS, and Javascript. Yes, there are plenty of such “free downloadable collapsible lists” all over the Internet. So here is one that is slightly different – A barebones no-bloat version, so you can build on top quickly. Read on! ⓘ I …

Very Simple Collapsible List (Pure HTML CSS JS ) Read More »

3 Ways To Do Case Insensitive String Comparison In Javascript

Welcome to a quick tutorial on how to do case insensitive string comparison in Javascript. By default, the == comparison operator in Javascript is case-sensitive. Just how can we do a case-insensitive comparison in Javascript then? The common ways to do a case-insensitive string comparison in Javascript are: Change both strings to lowercase – if …

3 Ways To Do Case Insensitive String Comparison In Javascript Read More »