How to Detect User Input with JavaScript

Поделиться
HTML-код
  • Опубликовано: 1 ноя 2022
  • In today's video I'll be going over a few techniques to detect changes to input fields or keyboard events with JavaScript. This is perfect for instant form validation or building games on the web.
    The 4 events covered are onchange, oninput, onkeydown and onkeyup.
    For your reference, check this out:
    developer.mozilla.org/en-US/d...
    🏫 My Udemy Courses - www.udemy.com/user/domenic-co...
    🎨 Download my VS Code theme - marketplace.visualstudio.com/...
    💜 Join my Discord Server - / discord
    🐦 Find me on Twitter - / dcodeyt
    💸 Support me on Patreon - / dcode
    📰 Follow me on DEV Community - dev.to/dcodeyt
    📹 Join this channel to get access to perks - / @dcode-software
    If this video helped you out and you'd like to see more, make sure to leave a like and subscribe to dcode!
    #dcode #javascript

Комментарии • 25

  • @spicyydiscord9084
    @spicyydiscord9084 9 месяцев назад +1

    This is such a good video. You explain it so simple. Thank you!!!

  • @robertaw1221
    @robertaw1221 Год назад +1

    Awesome demos

  • @collinsk8754
    @collinsk8754 Год назад

    Great stuff! 👍👍

  • @shamiul_islam
    @shamiul_islam Год назад

    Thank you. It's helpful.

  • @mandeepsingh-lu1ne
    @mandeepsingh-lu1ne 3 месяца назад

    You are great!

  • @mrshahcloud
    @mrshahcloud Год назад +2

    I use keyup event to change lowercase to uppercase from user input so the user can notice the animation

  • @justnow7263
    @justnow7263 Год назад +1

    You are amazing!.
    Thanks to this

  • @yinonelbaz5309
    @yinonelbaz5309 Год назад

    Awesome

  • @hrithikvishwakarma001
    @hrithikvishwakarma001 Год назад

    You're my fav one developer

  • @cyeg12c
    @cyeg12c Год назад

    Congrats for 100K subscriber 🎉

  • @neontuts5637
    @neontuts5637 Год назад

    Thanks for sharing Dom. You missed the "keypress" event.

    • @dcode-software
      @dcode-software  Год назад +2

      No problem. "keypress" is deprecated:
      developer.mozilla.org/en-US/docs/Web/API/Element/keypress_event

    • @neontuts5637
      @neontuts5637 Год назад

      @@dcode-software Thank You 🙇

  • @eboatwright_
    @eboatwright_ Год назад +1

    How would I go about getting input from the console? Also, congrats on 100k :)

    • @dcode-software
      @dcode-software  Год назад

      Hey, you can use prompt() to get input from the user using only JavaScript. Thank you!

    • @eboatwright_
      @eboatwright_ Год назад

      @@dcode-software AH, thanks!

  • @sambacarlson
    @sambacarlson Год назад

    Solved my bugs. * * * * *. in under a minute. I had to use event 'input' instead of 'change' to make a button work as expected.

  • @Hacking-NASSA-with-HTML
    @Hacking-NASSA-with-HTML Год назад +1

    mmm "How to write the simplest Keylogger" 😁???

  • @libanmohamed6403
    @libanmohamed6403 Год назад

    "Web Dev Made Easy" on youtube is stealing your tutorials and selling your source code in the description.... get ur bag sir

    • @dcode-software
      @dcode-software  Год назад

      Thank you for letting me know ☺️

    • @BrandonFunk
      @BrandonFunk Год назад

      @@dcode-software your a way better teacher than him, i cant listening to him talk. and he doesnt explain anything well. lol :P