mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-27 15:41:32 +08:00
10 lines
210 B
TypeScript
10 lines
210 B
TypeScript
import { getCurrentInstance } from 'vue';
|
|
|
|
// expose public api
|
|
export function useExpose<T>(apis: T) {
|
|
const instance = getCurrentInstance();
|
|
if (instance) {
|
|
Object.assign(instance.proxy, apis);
|
|
}
|
|
}
|