Set
Set 객체는 중복되지 않는 값들의 집합을 다루는 객체이다. 이를 이용하면 배열의 중복값을 제거할 수 있다. const set = new Set([1, 2, 3]);
JavaScript의 Set
객체는 값의 순서를 유지하지만, 배열과 같이 인덱스를 사용하여 특정 위치의 값을 직접 가져올 수는 없습니다.
만약 Set
에서 특정 위치의 값을 가져오고 싶다면, Set
객체를 배열로 변환한 다음에 인덱스를 사용하여 접근해야 합니다
This line appears after every note.
Notes mentioning this note
객체의 attribute
JavaScript에서 객체의 “특성(attribute)”은 대체로 객체의 메타 정보와 관련이 있습니다. 예를 들면, 속성은 객체의 프로퍼티가 변경 가능한지, 열거 가능한지, 설정 가능한지...