요약
신청 페이지의 다음 단계 핸들러 내부의 조건부 로직이 이중으로 들어가서 복잡함.
const handleClickNextStep = () => {
if (currentStep < TOTAL_STEPS) {
if (currentStep === 2 && applicationData.courses.length === 0) {
toast('최소 하나의 수업을 추가해주세요.');
return;
}
setCurrentStep((prev) => prev + 1);
}
};