The example below is number input which if contains "e" character will return "" empty string when accessed with JavaScript.
const input = document.querySelector('input');
input.oninput = (e) => console.log(e.target.value)
<input type="number">
Can you please explain the magic behind and possible way to prevent that from happening.
P.S: I am investigating the possibility to have input that will allow only [0-9] numbers on keyboard input/paste and will appreciate any suggestion on this topic :-)