JavaScript Events
Event interfaces available to event listeners in JavaScript.
- The DOMContentLoaded event can be used to tell when a page is fully loaded and ready to run scripts on the page; this may be useful if a script rely on dependencies that must be loaded for the script to work.
- the keydown event is not an ideal way to detect text-input by the user; instead you should consider using the input event.