You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello everyone!
I've got a minor problem with function init(). The Visual Studio Code says that the onkeypress event is deprecated. Could you tell me please what event should be used instead? As far as I managed to learn the onkeydown event fits best. Loads of thanks in advance!
Here is the snippet of code that I'm talking about:
function init() {
var fireButton = document.getElementById("fireButton");
fireButton.onclick = handleFireButton;
var guessInput = document.getElementById("guessInput");
guessInput.onkeypress = handleKeyPress;
}
The text was updated successfully, but these errors were encountered:
Hello everyone!
I've got a minor problem with function init(). The Visual Studio Code says that the onkeypress event is deprecated. Could you tell me please what event should be used instead? As far as I managed to learn the onkeydown event fits best. Loads of thanks in advance!
Here is the snippet of code that I'm talking about:
function init() {
var fireButton = document.getElementById("fireButton");
fireButton.onclick = handleFireButton;
var guessInput = document.getElementById("guessInput");
guessInput.onkeypress = handleKeyPress;
}
The text was updated successfully, but these errors were encountered: