When using <input type="time">
and setting the time with valueAsDate
the browser displays the time in GMT instead of local time, is there any way to change this behavior? I want the browser to display the local time.
If you're not on GMT time than you should see that the hour in the input is different the in the p
element
(I tried this in Chrome and Firefox)
let date = new Date;
document.querySelector("input").valueAsDate = date;
document.querySelector("p").innerText = date;
<input type="time">
<p></p>