-
Notifications
You must be signed in to change notification settings - Fork 0
Donggyu bugfix #127
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
Donggyu bugfix #127
Changes from all commits
74bf1e7
23efb0b
26c3b98
0b20e27
585332f
1b62d53
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
This file was deleted.
Large diffs are not rendered by default.
This file was deleted.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
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.
잠재적 버그 및 리스크
상태 관리 누락:
excludedIngredients상태가 초기화되거나 관리되지 않는 것으로 보입니다. 이로 인해 화면 전환 시 사용자가 식재료를 추가하거나 제거할 수 없게 될 수 있습니다.모달 표시 기능:
showDislikedModal상태는 정의되었지만, 모달을 표시하는 코드가 현재 포함되어 있지 않아 사용자에게 비선호 식재료를 추가하는 UI를 제공할 수 없습니다.에러 처리 개선: 현재 에러 처리 방식에서는, 서버에서 발생하는 모든 에러에 대해 단순히 메시지를 표시하는 것으로 끝납니다. 좀 더 신뢰할 수 있는 방식으로 서버의 응답코드에 대한 명시적인 처리가 필요합니다. 이로 인해 사용자가 잘못된 상태를 인지할 수 있도록 해줍니다.
개선 사항 제안
excludedIngredients의 상태를 추가하여 비선호 식재료 목록을 관리하세요. 예를 들어,useState를 사용해서 비선호 식재료를 초기화하고 변경사항을 추적할 수 있도록 하세요.모달 컴포넌트를 모달을 렌더링하는 부분에 포함시켜
showDislikedModal이 true일 때 모달이 화면에 나타나도록 구현하세요.에러 메시지를 더 풍부하게 만들어 사용자에게 정확한 피드백을 제공하고, 서버 에러일 경우 사용자가 다음에 무엇을 해야 할지 안내하는 내용을 추가하는 것이 유용합니다.