Answers for "how to get the day name from date in javascript"

6

how to get the day name from date in javascript

var days = ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'];
var d = new Date(dateString);
var dayName = days[d.getDay()];
Posted by: Guest on May-20-2021

Code answers related to "how to get the day name from date in javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language