본문 바로가기
currentTarget Target 차이 currentTarget Target 차이 Difference Property Click the inner square Click outside of the inner square currentTarget Outer square Outer square target Inner square Outer square currentTarget 이벤트가 바인딩 된 요소 the element that the event was bound to. It never changes. In the sample code above, e.currentTarget is the element. target 사용자가 클릭 한 요소 사용자가 정확히 클릭하는 위치에 따라 원래 요소 또는 하위 요소가 될 수 있다. the element us.. 2020. 9. 21.
CSS variables How to use Custom properties CSS variables var() Custom properties (--*): CSS variables 사용자 지정 속성, 또는 "CSS 변수"의 값을 다른 속성의 값으로 지정할 때 사용 와 --같이 접두사가 붙은 속성 이름 은 함수를 사용하는 다른 선언에서 사용할 수있는 값을 포함하는 사용자 지정 속성 을 --example-name나타낸다. :root { --main-color: #488cff; --second-color: #ffff8c; } #firstParagraph { background-color: var(--first-color); color: var(--second-color); } 정의 : 사용자 지정 속성은 전용 표기법을 사용해 정의 .. 2020. 9. 21.
JS Map, Filter, Reduce How to properly use Javascript Map, Filter, and Reduce 자바스크립트 고차함수 map, filter, reduce 사용하기 Sample Player list Array const players = [ { id: 10, name: "Jan Vertonghen", status: "Goal keeper", totalMatch: 400, retired: true, }, { id: 2, name: "Paulo Wanchope", status: "Attacker", totalMatch: 200, retired: false, }, { id: 41, name: "Ronny Johnsen", status: "Goal keeper", totalMatch: 300, retired: .. 2020. 9. 21.