Closed hyesungoh closed 1 year ago
온보딩에서 홈으로 넘어갈 때 카테고리 조회, 사용자 템플릿 조회 (카테고리가 선택된 상태에서) 이 두 개의 조회가 이루어져요
카테고리 조회
사용자 템플릿 조회 (카테고리가 선택된 상태에서)
문제는 카테고리 조회 이후에 초기 첫 번째 카테고리를 전역 상태로 set하는 과정에 있었는데요
현재 선택된 카테고리가 있을 경우 넘어가는 로직을 !== null로 비교를 해서 발생했었어요.
!== null
조회되기 전 (로딩중 일 때) null이 아닌 undefined가 set된 이후에, 조회된 후 set을 할려는데 undefined !== null이라 발생했었어요!
undefined !== null
Compared against afeace33b70ae438682384a853f18a580b53e0f1
Route: No significant changes found
Dynamic import: No significant changes found
🤔 해결하려는 문제가 무엇인가요?
🎉 어떻게 해결했나요?
온보딩에서 홈으로 넘어갈 때
카테고리 조회
,사용자 템플릿 조회 (카테고리가 선택된 상태에서)
이 두 개의 조회가 이루어져요문제는 카테고리 조회 이후에 초기 첫 번째 카테고리를 전역 상태로 set하는 과정에 있었는데요
현재 선택된 카테고리가 있을 경우 넘어가는 로직을
!== null
로 비교를 해서 발생했었어요.조회되기 전 (로딩중 일 때) null이 아닌 undefined가 set된 이후에, 조회된 후 set을 할려는데
undefined !== null
이라 발생했었어요!📚 Attachment (Option)