Open in app

Sign In

Write

Sign In

John Au-Yeung
John Au-Yeung

66K Followers

Home

About

1 day ago

How to Check If a Value Exists in an Object Using JavaScript?

Sometimes, we want to check if a value exists in an object with JavaScript. In this article, we’ll look at how to check if a value exists in an object with JavaScript. Use the Object.values Method We can use the Object.values method to return an array of property values of an object. Therefore, we…

Programming

2 min read

How to Check If a Value Exists in an Object Using JavaScript?
How to Check If a Value Exists in an Object Using JavaScript?
Programming

2 min read


Published in JavaScript in Plain English

·4 days ago

How to Check if a JavaScript String is Entirely Made of the Same Substring

Sometimes, we want to check if a JavaScript string is entirely made of the same substring. In this article, we’ll look at how to check if a JavaScript string is entirely made of the same substring. Use the String.prototype.indexOf Method We can use the indexOf method to return the index of the first instance…

Programming

2 min read

How to Check if a JavaScript String is Entirely Made of the Same Substring
How to Check if a JavaScript String is Entirely Made of the Same Substring
Programming

2 min read


Published in JavaScript in Plain English

·Jan 21

How to Find the Size of Local Storage with JavaScript

Sometimes, we want to find the size of our browser’s local storage with JavaScript. In this article, we’ll look at how to find the size of our browser’s local storage with JavaScript. Convert to a Blob We can convert our browser’s local storage object into a blob to get the size of it. To…

Programming

2 min read

How to Find the Size of Local Storage with JavaScript
How to Find the Size of Local Storage with JavaScript
Programming

2 min read


Published in JavaScript in Plain English

·Jan 18

How to Convert a JavaScript Array into a String

Sometimes, we want to convert a JavaScript array into a string. In this article, we’ll look at how to convert a JavaScript array into a string. Concatenate a String to an Array One way to convert a JavaScript array into a string is to concatenate an empty string after it. For instance, we can write: const…

Programming

2 min read

How to Convert a JavaScript Array into a String
How to Convert a JavaScript Array into a String
Programming

2 min read


Published in JavaScript in Plain English

·Jan 14

How to Calculate the Day of the Year with JavaScript?

Sometimes, we want to calculate the day of the year with JavaScript. In this article, we’ll look at how to calculate the day of the year with JavaScript. Calculate the Day of the Year with JavaScript We can calculate the day of the year with JavaScript with some native date methods. For instance, we can write: const now…

Programming

2 min read

How to Calculate the Day of the Year with JavaScript?
How to Calculate the Day of the Year with JavaScript?
Programming

2 min read


Published in JavaScript in Plain English

·Jan 11

How to Map Over a JavaScript Object While Preserving the Keys

Sometimes, we want to map the property values of a JavaScript object to another value while preserving the keys. In this article, we’ll look at how to map the property values of a JavaScript object to another value while preserving the keys. Lodash mapValues Method We can use the Lodash mapValues method to…

Programming

2 min read

How to Map Over a JavaScript Object While Preserving the Keys
How to Map Over a JavaScript Object While Preserving the Keys
Programming

2 min read


Published in JavaScript in Plain English

·Jan 7

How to Join JavaScript Strings with a Delimiter Only if the Strings are not Null or Empty

Sometimes, we want to join JavaScript strings together with a delimiter only if the strings aren’t null or empty. In this article, we’ll look at how to join JavaScript strings together with a delimiter only if the strings aren’t null or empty. Use the Array.prototype.filter Method We can use the JavaScript array filter method…

Programming

2 min read

How to Join JavaScript Strings with a Delimiter Only if the Strings are not Null or Empty
How to Join JavaScript Strings with a Delimiter Only if the Strings are not Null or Empty
Programming

2 min read


Published in JavaScript in Plain English

·Jan 5

How to Define an HTML Template and Append it Using JQuery

Sometimes, we want to define an HTML template and append it to our HTML document with jQuery. In this article, we’ll look at how to define an HTML template and append it to our HTML document with jQuery. Use the jQuery append Method We can use the jQuery append method with a script tag that…

Programming

2 min read

How to Define an HTML Template and Append it Using JQuery
How to Define an HTML Template and Append it Using JQuery
Programming

2 min read


Published in JavaScript in Plain English

·Dec 31, 2022

How to Remove a File from a JavaScript FileList?

Sometimes, we want to remove a file from a JavaScript FileList object. In this article, we’ll look at how to remove a file from a JavaScript FileList object. Use the Spread Operator One way to remove a file from a JavaScript FileList is to use the spread operator to convert the FileList to an…

Programming

2 min read

How to Remove a File from a JavaScript FileList?
How to Remove a File from a JavaScript FileList?
Programming

2 min read


Published in JavaScript in Plain English

·Dec 28, 2022

How to Get the Day of the Week and the Month of the Year with JavaScript?

Sometimes, we want to get the day of the week and the month of the year with JavaScript. In this article, we’ll look at how to get the day of the week and the month of the year with JavaScript. Get the Day of the Week To get the day of the week, we can use…

Programming

2 min read

How to Get the Day of the Week and the Month of the Year with JavaScript?
How to Get the Day of the Week and the Month of the Year with JavaScript?
Programming

2 min read

John Au-Yeung

John Au-Yeung

66K Followers

Web developer. Check out https://thewebdev.info. Email me at hohanga@gmail.com

Following
  • Mahesh Sharma

    Mahesh Sharma

  • Adam, Diabetic Cyborg

    Adam, Diabetic Cyborg

  • Dr Mark van Rijmenam

    Dr Mark van Rijmenam

  • Dale Clifford

    Dale Clifford

  • Lanu Pitan

    Lanu Pitan

Help

Status

Writers

Blog

Careers

Privacy

Terms

About

Text to speech