date object to iso string javascript code example Example: get iso date javascript var isoDate = new Date().toISOString()