Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

is event.target deprecated?

MDN Web Docs specifications table for event.target indicates that it's status is obsolete in DOM level 2 and DOM4. does it mean it's deprecated and I no longer should use it?
If so what should I use instead?
I know my question is somehow ridiculous, cause event.target is so important and we use it everywhere, but I couldn't find something useful on the net, specially W3.org, and I'm still obsessed with the word Obsolete :), so I preferred to ask here. thanks

like image 584
amirify Avatar asked Jun 09 '26 13:06

amirify


1 Answers

You're misinterpreting MDN.

It says that the DOM4 and Document Object Model (DOM) Level 2 Events Specification's definitions of Event.target are obsolete, not that Event.target itself is obsolete.

The DOM (Living Standard) specification is not marked as obsolete and you should use that definition.

like image 90
Quentin Avatar answered Jun 12 '26 01:06

Quentin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!