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

[FE] fix: 검색 결과 두 번 요청 수정 #676

Merged
merged 1 commit into from
Sep 20, 2023
Merged

Conversation

Leejin-Yang
Copy link
Collaborator

Issue

✨ 구현한 기능

  • 검색 결과 요청 쿼리에 debounced 값 대신 searchQuery로 변경

📢 논의하고 싶은 내용

  • 논의하고 싶은 내용을 작성합니다.

🎸 기타

  • 특이 사항이 있으면 작성합니다.

⏰ 일정

  • 추정 시간 :
  • 걸린 시간 :

@github-actions
Copy link

Test Results

8 tests   - 216   8 ✔️  - 216   6s ⏱️ -20s
3 suites  - 109   0 💤 ±    0 
1 files    - 111   0 ±    0 

Results for commit 153ee0c. ± Comparison against base commit 66a2147.

Copy link
Collaborator

@xodms0309 xodms0309 left a comment

Choose a reason for hiding this comment

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

근데 왜 debouncedSearchQuery를 쓸 때 요청을 2번 보내는거였나요?/

@Leejin-Yang
Copy link
Collaborator Author

@xodms0309
입력값: 삼, 자동완성: 삼각김밥 클릭

  • 삼각김밥 클릭
  • isSubmitted가 true
  • 입력값 삼이 삼각김밥으로 상태 업데이트 늦음
  • submit: true, 삼 요청, 업데이트되면서 submit: true, 삼각김밥 요청
  • 그래서 debouncedQuery를 searchQuery로 바꿈
  • isSubmitted와 searchQuery 업데이트 시점을 동일하게 해줘서 해결~

Copy link
Collaborator

@hae-on hae-on left a comment

Choose a reason for hiding this comment

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

👍

@Leejin-Yang Leejin-Yang merged commit 5c52727 into develop Sep 20, 2023
3 checks passed
@Leejin-Yang Leejin-Yang deleted the fix/issue-674 branch September 20, 2023 06:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FE] 자동 완성 검색어 클릭으로 검색 시 중복 요청
3 participants