JavaScript na Focus Lost

<input type="text" onfocusout="myFunction()">
<script>
  function myFunction(){
 	console.log("Focus Lost!") 
 }
</script>
Undefined