Skip to content
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

[feat/CK-212] 로드맵 생성페이지 오류를 해결한다. #171

Merged
merged 6 commits into from
Sep 30, 2023

Conversation

NaveOWO
Copy link
Collaborator

@NaveOWO NaveOWO commented Sep 29, 2023

📌 작업 이슈 번호

CK-212

✨ 작업 내용

로드맵 생성페이지 오류 해결했습니다.

  • 요청이 잘못되었을 때 다시 요청보낼 수 없는 오류 해결
  • 난이도 요청 잘못가는 오류 해결
  • 태그 무한생성오류 해결
  • 중복되는 태그가 생성되는 오류 해결
  • 로드맵의 첫번째 노드 기본으로 노출시킴

💬 리뷰어에게 남길 멘트

잘부탁드림당~

🚀 요구사항 분석

@NaveOWO NaveOWO added fix ⚒️ Something isn't working FE 👨‍👨‍👧 FrontEnd labels Sep 29, 2023
@NaveOWO NaveOWO self-assigned this Sep 29, 2023
@NaveOWO NaveOWO changed the title Feature/ck 212 [feat/CK-212] 로드맵 생성페이지 오류를 해결한다. Sep 29, 2023
jw-r
jw-r approved these changes Sep 30, 2023
Comment on lines +10 to +14
VERY_EASY: '매우쉬움',
EASY: '쉬움',
NORMAL: '보통',
DIFFICULT: '어려움',
VERY_DIFFICULT: '매우어려움',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

오옥 ㅋㅋㅋ
이걸 고쳤네

대박 고생하셨어요🤩


export type DifficultyValueType = '매우쉬움' | '쉬움' | '보통' | '어려움' | '매우어려움';

export type DifficultiesType = { [key in DifficultyKeyType]: DifficultyValueType };
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

잊혀지지 않는 타입스크립트 문법 ㅋㅋ 👍

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

킄킄 이걸 알아먹다니

Comment on lines 9 to 10
if (ref.current === null) return;
if (ref.current.value === '') return;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

사소하지만 아래와 같이 단순화할 수 있을 것 같습니다!

if (!ref.current?.value) return;

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

너무 똑똑해서 화가 다 나네요..

@@ -27,7 +30,7 @@ export const useCollectRoadmapData = () => {
}));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DummyCategoryType가 아직 사용되고 있네요
이제 타입을 수정해줘도 괜찮을 것 같아요!

@jw-r jw-r self-requested a review September 30, 2023 09:23
Copy link
Collaborator

@jw-r jw-r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

디버깅이 쉽지 않았을텐대 정말 고생하셨어요!
👍👍👍👍👍👍👍👍👍

코맨트 확인 부탁드려요🤩

@jw-r jw-r self-requested a review September 30, 2023 13:02
Copy link
Collaborator

@jw-r jw-r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

넘 고생하셨어요!!!

Copy link
Collaborator

@sh981013s sh981013s left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

크으으... 진짜 싹다 고치셨군요 👍 너무 고생하셨어요 ㅎㅎ 코멘트 몇개만 확인 부탁드려요!

Comment on lines +63 to 64
{getInvariantObjectKeys(invariantOf(Difficulties)).map((difficulty, idx) => {
return (
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getInvariantObjectKeys(invariantOf(Difficulties))[selectedOption] 와 같은 코드가 여러 번 나타나고 있는 것 같아요!.로직을 추가로 별도의 유틸리티 함수로 분리하는 것은 불가능할까요? 😀

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

험.... 이미 유틸로 빼져있는 함수라서 이부분은 더 고민해볼께요!!

@@ -27,7 +30,7 @@ export const useCollectRoadmapData = () => {
}));
};

const getSelectedDifficulty = (difficulty: keyof DummyDifficultyType | null) => {
const getSelectedDifficulty = (difficulty: DifficultyKeyType | null) => {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getSelectedDifficulty라는 메서드 이름은 "get"이라는 동사를 사용하고 있지만, 실제로는 값을 설정(set)하는 역할을 하는 것처럼 보이는데 네이밍을 바꾸면 어떨까요?? 😀

@NaveOWO NaveOWO merged commit 1154295 into develop-client Sep 30, 2023
1 check passed
@younghoondoodoom younghoondoodoom deleted the feature/CK-212 branch December 10, 2023 10:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FE 👨‍👨‍👧 FrontEnd fix ⚒️ Something isn't working
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants