Let say that I want to find the types of attributes attached to a HTML element. To be clear, I don't want to list the attributes of an element, for each attribute I would like to find it's attribute type, and not it's value or name.
eg. I have a div with several attributes, I want to print to the console the types of attributes that are attached to the element. in this case it should print an array with the value [event]
<div onclick='someFunc()'>some text</div>
getAttribuyteType() // event
Asked
Active
Viewed 79 times
1

Shai Kimchi
- 746
- 1
- 4
- 22
-
[element.attributes](https://developer.mozilla.org/en-US/docs/Web/API/Element/attributes) – adeneo May 15 '17 at 14:28