-
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
issue#25 api 리팩토링 #60
Conversation
- axios instance를 swagger-typescript-api HttpClient로 생성
- next-safe-action 제거, useMutation 사용 - login api 호출 swagger-typescript-api 사용
- auth interceptor를 적용한 instance 사용가능하게 확장
- fail request가 여러 개 일 때를 대비해 queue로 request 관리 - reissue api 호출 부분 모듈화
- axios instance 자체를 넘기게 수정
- /activity/{activityName} 에서 /activity/{activityId}로 수정 - 규모가 커져서 따로 이슈 생성 후 진행할 예정
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.
다시 보면서 생각해보니까 스웨거 관련 api 코드가 엄청 복잡한 느낌은 아니긴하네요. 고생많으셨습니다.
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.
확인했습니다~~ 수고하셨어요🌝
Merry Christmas🎅🏻
toast가 공통 컴포넌트군요
api 관련은 /service에서 임포트해서 쓰면 되는 거죠?
늦었지만 메리크리스마스🎄💝 toast도 shacn, radix 라이브러리를 사용한 컴포넌트입니당 자세한 사용법은 아래 공식문서 확인해주세욤
넹 맞습니다 /service 폴더가 api 관련 폴더라고 생각하면 됩니다! |
개발 진행을 위해 먼저 머지하겠습니당 |
📝 상세 내용
#️⃣ 이슈 번호
🔗 참고 자료
📷 스크린샷(선택)
업데이트 된 swagger 명세서 적용하는 방법
npm run swagger-typescript-api
입력./src/models
에 도메인별로 생성된 class 확인./src/service/models/도메인
에 추가하기extends HttpClient<SecurityDataType>
를extends CustomHttpClient<SecurityDataType>
로 변경하기./src/service/api/도메인
에 class로 API 호출하기./src/models
모든 파일 제거하기