How to Detect Enter Key Press in Javascript

preview_player
Показать описание
In this video, you will learn how to detect enter key press using javascript. I hope you'll like the video and leave your feedback and suggestions for future video tutorials.

Source Code:

0:00 HTML
1:01 Javascript
2:00 Final Output
Рекомендации по теме
Комментарии
Автор

Thank you sir, this was very helpful for one of my projects I was working on!

codingwithkenny
Автор

You are a good English speaker even when you are an Indian. Also hats off your code.

vijaypawar
Автор

Thank you brother. This really helped me :)

aminozuur
Автор

Unfortunately the keyCode feature is deprecated and no longer supported in most browsers. Thanks for showing it though !

TuyaTheNasty
Автор

Thanks a lot, iam searching this metod so muxh

muhamadhafizputrapratama
Автор

nice keyboard sound.
I always want to find something like that for myself.

somnvm
Автор

Sir I like this video but I want that on button click it happen

laksya
Автор

keyCode is now depricated. The alternative is to just simply use key:
if (e.key === 'Enter')

MohitMummon
Автор

Why didnt you create the js file before and wasted 1 minute

ozlemucar
Автор

Keyup doesn't work. Keydown is correct.

FrankyyBalboa