import { provide, inject} from 'vue';
import type ProvideType from '@/ProvideConfig'

export function useProvide<T>(key: ProvideType, value: T): void{
  provide(key, value)
}

export function useInject<T>(key: ProvideType): T {
  return inject<T>(key) as T;
}