How to Build a Custom Design System
Building an editorial tech blog avoiding common UI framework traps.
지난 몇 년간 React에서 Effect와 Event를 구분하는 것은 늘 골치 아픈 문제였습니다. 많은 개발자들이 의존성 배열 경고를 무시하거나, 불필요한 렌더링을 유발하는 코드를 작성하곤 했습니다.
function helloWorld() {
console.log("Hello, world!");
}
위 코드에서는 logInteraction이 매번 새로 생성되면서 effect가 재실행되는 문제가 발생합니다. 이를 억제하기 위해서는 useEventCallback 같은 꼼수를 써야 했습니다.
Building an editorial tech blog avoiding common UI framework traps.