<input type="date> onchange fires too much

You could use both handlers. Use the onChange to flag that the input has changed, and on the onBlur handler, check to see if it has been changed before doing whatever logic you need to do.


<input type="date" id="mydate">

And Js:

let mydate=window.document.getElementById("mydate");
let olddate=mydate.value;
let isChanged = function(){
  if(mydate.value!== olddate){
    olddate=mydate.value;
    return true;
  };
  return false;
};
mydate.addEventListener("blur", function(){
  if(isChanged())
    alert("changed!");
});