loading...

re: How do I detect if the '+' key is pressed (without the shift) VIEW POST

FULL DISCUSSION
 

when keydown and some other events, an event has key property that has name of your keyboard key button.

input.addEventListener('keydown', function(e) {
  if (e.key === '+') {
    // ... do your code
  }
});
Code of Conduct Report abuse