-
Notifications
You must be signed in to change notification settings - Fork 3
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
Feature #71 - LotusList 페이지 구현 #72
Conversation
- 추후 loading, error fallback 변경 필요
- 추후에 query key 관리 방법 변경 필요
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 구현하신 줄 알았어요...👍 수고하셨습니다!!
const url = new URL(request.url); | ||
const page = url.searchParams.get('page'); | ||
const size = url.searchParams.get('size'); | ||
const search = url.searchParams.get('search'); |
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.
public lotus 목록 조회에서 search는 우선 제외한 건가요??
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.
넹 search는 일단 빼두고 작업했습니당
import { LotusType } from './type'; | ||
|
||
export const getLotusList = async ({ page = 1 }: { page: number }) => { | ||
const res = await fetch(`/api/lotus?page=${page}`); |
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.
저희는 fetch랑 axios 중에 fetch로 쓰나용? axios 사용해봐도 좋을 것 같아서요!
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.
axios 써도 좋을거 같네요!
}); | ||
|
||
export const Route = createFileRoute('/(main)/lotus/')({ | ||
validateSearch: (search) => lotusSearchValidation.parse(search) |
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.
저도 이거 때문에... 고생을 좀,...
#️⃣연관된 이슈
#71
📝작업 내용
스크린샷 (선택)
💬리뷰 요구사항(선택)
네이밍이 이상하거나 이해가 가지 않는 부분 모두 코멘트 남겨주세요!
모킹은 순차적으로 동적으로 변경해볼 예정입니다.
파일 경로나 query-key 구조화 같은 경우에는 추후에 정리가 필요해보입니다.