javascriptFind which DOM element has the focus
var focused = document.activeElement;ctrl + cdocument.activeElementreturns currently focused element (docs) |
More of Javascript
- Create array with N random elements (1...N range)
- Get a timestamp
- Access object key by variable
- Insert text into textarea at cursor position
- Get query parameter value of specified URL
- Generate UUID
- Sleep
- Validate email
- Round to 1 decimal
- Get all children and grandchildren of an html element recursively
See more codes...