import {injectLocal, provideLocal} from "@vueuse/core";

const key = Symbol('PROVINCE_SERVICE')
export const useProvideProvince = function (optionsRefOrGetter) {
    provideLocal(key, {provinceOptions: optionsRefOrGetter})
    return optionsRefOrGetter
}

export const useInjectProvince = function (defaultValue) {
    return injectLocal(key, defaultValue)
}