> For the complete documentation index, see [llms.txt](https://shhn0509.gitbook.io/hanna/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://shhn0509.gitbook.io/hanna/hanna-log/march/16.md).

# 16일

## 3/16&#x20;

#### React

* 클래스 컴포넌트의 setState()는 두번 째 인자로 callback 함수를 가질 수 있다.&#x20;

```javascript
setState(updater, [callback])
```

* `{ return } === ()`&#x20;
* setState 복습 &#x20;
* classNames 사용 방법&#x20;

#### CSS&#x20;

* CSS 다중 선택자 사용하기&#x20;

```css
/* 선택자를 다중 선택하고 싶다면  */
.validState label {
  top: 6px;
  left: 20px;
  font-size: 1.2rem;
}
.invalidState label {
  top: 6px;
  left: 20px;
  font-size: 1.2rem;
}

/* 아래와 같이 ,(콤마)를 사용해서 선택한다. */
.invalidState label,
.validState label {
  top: 6px;
  left: 20px;
  font-size: 1.2rem;
}
```

* X + Y 선택자는 다음 형제 요소만 선택할 수 있다. 이전 형제는 선택 할 수 없다. \
  이전 형제 요소를 선택하고 싶다면 previousSibling을 사용하자.&#x20;
* [currentColor 키워드 ](https://shhn0509.gitbook.io/html/stylesheet/style/untitled-1#currentcolor_%ED%82%A4%EC%9B%8C%EB%93%9C)
