[groups] tableData build시 에러로 다시 올림

This commit is contained in:
2025-07-10 15:10:41 +09:00
parent 757deae40e
commit ffacf689f9
2 changed files with 8 additions and 11 deletions
@@ -4,6 +4,14 @@ import { type GroupListResponseDto } from "@/entities/group";
import { MenuAuthorityDialog } from "../ui/menu-authority-dialog";
import { GroupsDialog } from "../ui/groups-dialog";
declare module "@tanstack/react-table" {
// eslint-disable-next-line @typescript-eslint/no-unused-vars
interface TableMeta<TData> {
onDelete: (groupId: string) => void;
}
}
export const columns: ColumnDef<GroupListResponseDto>[] = [
{
accessorKey: "groupId",
-11
View File
@@ -1,11 +0,0 @@
import '@tanstack/react-table';
// 오류가 표시되는 이유는 TypeScript가 meta 객체 안에 onDelete라는 속성이 존재한다는 것을 모르기 때문입니다
declare module '@tanstack/react-table' {
// TData는 테이블의 row 데이터 타입을 의미합니다.
// interface TableMeta에 우리 프로젝트에서 사용할 커스텀 속성의 타입을 정의합니다.
interface TableMeta<TData extends RowData> {
// handleDelete 함수가 string 타입의 인자를 받으므로, 타입을 명시해줍니다.
onDelete: (groupId: string) => void;
}
}