Refactor useToast hook
The useToast hook was refactored into smaller, more manageable files to improve code organization and maintainability.
This commit is contained in:
9
src/hooks/toast/store.ts
Normal file
9
src/hooks/toast/store.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
|
||||
import { State } from './types'
|
||||
|
||||
// 전역 상태 및 리스너
|
||||
export const listeners: Array<(state: State) => void> = []
|
||||
export let memoryState: State = { toasts: [] }
|
||||
|
||||
// 마지막 액션 추적 (중복 방지용)
|
||||
export let lastAction: { type: string; id?: string; time: number } | null = null
|
||||
Reference in New Issue
Block a user