Tag: utility function

Recent Post

Random Image with JavaScript

You can use JavaScript to display a random image, both on page load and when a user clicks to get ano

Check Total, Used and Remaining Space Available in localStorage

By pushing data into loca, it is possible to calculate total and available space.

Export a JavaScript array as a CSV file on the client-side

Make an array available for download in CSV format.

Automated title capitalization with JavaScript

How to create a title capitalization function in JavaScript.

The right way to generate a random number in JavaScript

In JavaScript, you can generate a weakly random number quickly or a strongly random number slowly.

Find the index of an element in a JavaScript array by value

Get the index value of any element in an array by value and instance of its appearance.

HTML Table of Contents Generator

A JavaScript solution for generating a table of contents for HTML content.

Currency formatting in JavaScript

How to convert a numeric values to a currency value using the native Internationalization API.

Create a unique ID in JavaScript

Create a unique ID to identify a user or session with an embedded creation timestamp.

Merging several strings into one in JavaScript

Learn how to merge multiple strings into one in various formats, including a comma-separated list.