Fix TS2686 error in syncResultHandler
The file `src/hooks/sync/syncResultHandler.ts` was throwing a TS2686 error because it was using `React` without importing it, even though it's a module. This commit adds `import React from 'react';` to resolve the issue.
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
|
|
||||||
|
import React, { useEffect } from 'react';
|
||||||
import { SyncResult } from '@/utils/sync/data';
|
import { SyncResult } from '@/utils/sync/data';
|
||||||
import { toast } from '@/hooks/useToast.wrapper';
|
import { toast } from '@/hooks/useToast.wrapper';
|
||||||
import useNotifications from '@/hooks/useNotifications';
|
import useNotifications from '@/hooks/useNotifications';
|
||||||
@@ -79,7 +80,7 @@ export const useSyncNotifications = () => {
|
|||||||
const { addNotification } = useNotifications();
|
const { addNotification } = useNotifications();
|
||||||
|
|
||||||
// 컴포넌트 마운트 시 알림 함수 설정
|
// 컴포넌트 마운트 시 알림 함수 설정
|
||||||
React.useEffect(() => {
|
useEffect(() => {
|
||||||
setSyncNotificationAdder(addNotification);
|
setSyncNotificationAdder(addNotification);
|
||||||
return () => setSyncNotificationAdder(null);
|
return () => setSyncNotificationAdder(null);
|
||||||
}, [addNotification]);
|
}, [addNotification]);
|
||||||
|
|||||||
Reference in New Issue
Block a user