Skip to content

Commit dbb8d19

Browse files
committed
Remove: 필요없는 주석 삭제
1 parent 9cd4fa2 commit dbb8d19

File tree

1 file changed

+0
-36
lines changed

1 file changed

+0
-36
lines changed

hooks/queries/useGetCommentList.tsx

-36
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,3 @@
1-
// import { useInfiniteQuery } from '@tanstack/react-query';
2-
// import { CommentList } from '@/types/types';
3-
// import { getCommentList } from '@/service/board';
4-
// import { useEffect } from 'react';
5-
// import { useInView } from 'react-intersection-observer';
6-
7-
// export default function useGetCommentList(boardId: number) {
8-
// const { data, isLoading, hasNextPage, fetchNextPage, isFetchingNextPage } =
9-
// useInfiniteQuery<CommentList>({
10-
// queryKey: ['commentList'],
11-
// queryFn: ({ pageParam = 0 }) => getCommentList(pageParam, boardId),
12-
// getNextPageParam: (commentList) =>
13-
// commentList.last ? undefined : commentList.number + 1,
14-
// });
15-
// // 무한 스크롤 화면 가장 아래 부분 탐지하는 observer
16-
// function Observer({ children }: { children: React.ReactNode }) {
17-
// const { ref, inView } = useInView({ threshold: 1 });
18-
// useEffect(() => {
19-
// if (inView && hasNextPage) {
20-
// fetchNextPage();
21-
// }
22-
// }, [inView]);
23-
// if (!hasNextPage || !data) return null;
24-
// return (
25-
// <div ref={ref}>{isLoading || isFetchingNextPage ? children : null}</div>
26-
// );
27-
// }
28-
29-
// return {
30-
// data,
31-
// isLoading,
32-
// Observer,
33-
// hasNextPage,
34-
// };
35-
// }
36-
371
'use client';
382

393
import { getCommentList } from '@/service/board';

0 commit comments

Comments
 (0)