본문 바로가기
TIL/TIL

Node vs Element

by koreashowme 2020. 2. 13.

Element는 < Node에 속해 있음.

 

ex)

div

 1) PASSWORD  2) <input type="password" />   3)

/div

 

1) text 노드

2) input Element

3) 공백 text 노드 

 

해당 객체 .child 하면 해당 Element만 나옴.

 

 

EventTarget <= Node <= Element

 

 

 

 

 

 

 

 

 

'TIL > TIL' 카테고리의 다른 글

querySelecter VS querySelecterAll  (0) 2020.02.14
어떻게 HTMLElement를 JavaScript를 통해 가지고 올 수 있을까?  (0) 2020.02.14
DOM  (0) 2020.02.13
id 및 class 목적에 맞게 사용하기  (0) 2020.02.13
프로토타이핑  (0) 2020.02.13

comment