-
Notifications
You must be signed in to change notification settings - Fork 1
✨ HTMLViewer에 MainImage 기능 추가 #18
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
import { usePathname } from 'next/navigation'; | ||
|
||
import { SegmentNode, main } from '@/types/page'; | ||
|
||
export default function useCurrentSegmentNode(): SegmentNode { |
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.
아마 내비 만들 때까지만 해도 hooks 폴더가 없었을 거라 여기에 써두었을 것으로 추정되는데 얘도 훅이라면 hooks
에 넣는 건 어떠신가요!
이 함수 밑에 있는 findChildWithName
은 페이지들이랑 관련된 것 같으니 utils/page.ts
에 넣어놓고...?
크게 중요한 부분은 아니니 애매하다면 편한 대로 해도 무방할 듯합니다!
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.
findChildWithName은 export할 필요가 없어서 useCurrentSegmentNode랑 같이 가도 좋을 것 같고, useCurrentSegmentNode는 hooks로 옮길게요!
변경 사항
추가 사항