This is a simple app I designed to checkout keyboard key codes of the various keys on the computer keyboard when clicked.
The code below is the major key in the code 😄 (please forgive my pun).
window.addEventListener('keydown', function (event) {
kbdCode.innerText = event.keyCode;
console.log(event) // returns a key code object
}
from the object when you press the A
character key, the event.key
returns A
while the event.code
returns KeyA
. there are other properties from the event object
to check out too.
you can checkout the Keyboard key code app
Hi all, this right here is me learning how to write a README.md file. So here's my first. Thanks.