let mdy = ['month', 'date', 'year']; let hms = ['hour', 'minute', 'second']; mdy = new Date().toLocaleDateString("en-US").split("/"); hms = new Date().toLocaleTimeString("en-US").split(/:| /); console.log(mdy,hms);