강의

멘토링

커뮤니티

Inflearn Community Q&A

insung9405538's profile image
insung9405538

asked

[Renewal] Introduction to JavaScript in Zero Seconds through Coding Self-Study

Parent-child relationship, pseudoarray, every, some, flat

target.cellIndex 확인하는 방법이 있을까요?

Written on

·

201

0

const row = target.parentNode.row; 
const cell = target.cell;
const row = target.parentNode.rowIndex;
const cell = target.cellIndex;

계속 변수명 바꾸면서 왜 안 되나 싶었는데 idex가 메서드였군요..

 

혹시 위 사진처럼 cellIndex를 확인 할 수 있는 방법이 있을까요?

javascript

Answer 1

0

zerocho님의 프로필 이미지
zerocho
Instructor

메서드는 아니고 프로퍼티(속성)입니다.

console.log(target.cellIndex) 해보심 됩니다.

insung9405538님의 프로필 이미지
insung9405538
Questioner

아하 그렇군요

insung9405538's profile image
insung9405538

asked

Ask a question