-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FE] refactor: LandingPage에서 사용하는 Input 유효성 검사 함수 분리 및 테스트 작성 #349
[FE] refactor: LandingPage에서 사용하는 Input 유효성 검사 함수 분리 및 테스트 작성 #349
Conversation
return input.length <= length; | ||
}; | ||
|
||
const MAX_VALID_REVIEW_GROUP_DATA_INPUT = 50; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이 상수 부분은 폼 로직과 관련된 값입니다. 이 상수를 컴포넌트 파일에 둘지 여기다 둘지 고민했는데 이 유틸 함수를 해당 컴포넌트에서만 사용한다고 가정했기 때문에,(추후 기본 함수들은 전역으로 뺄 수도 있겠지만) 해당 컴포넌트의 유효성 검증을 위한 파일로 만들자고 생각해서 일단 여기에 두기로 했습니다
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
테스트 까지 고생했어 올리
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
테스트 작성하느라 고생했어요!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생했어요! 사소한 궁금증이 있어 코멘트 남겼어요.
export const isNotEmptyInput = (input: string) => { | ||
return input !== ''; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
사소하지만 부정 조건문으로 판단한 이유가 있을까요?
🚀 어떤 기능을 구현했나요 ?
🔥 어떻게 해결했나요 ?
📝 어떤 부분에 집중해서 리뷰해야 할까요?
📚 참고 자료, 할 말