Replies: 1 comment
-
좋아요! 공식 문서를 읽어봤는데 popState 이벤트가 발생하기 전에 수행될 로직을 콜백함수로 넘겨주면 되는 것 처럼 보이네요! 이슈를 해결하는데 딱 적절한 router 메서드인 것 같습니다 👍 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
현재 TopNavigation 컴포넌트에서 뒤로가기 아이콘을 클릭하면
router.back()
이 동작됩니다!사용자가 메인화면부터 차례대로 페이지에 접근한 것이 아니라 url로 상세 페이지 등에 접근한 경우, 뒤로가기를 누르면 다독다독을 벗어나게 됩니다.
이 때 메인 화면으로 이동시키면 좋을 것 같아요.
next/router의 routerBeforePopState api를 사용하면 해결할 수 있을지 않을까 생각해봤어요! 어떠신가요??
Beta Was this translation helpful? Give feedback.
All reactions