liuyu
昨天 93c133349a5ccd7a328371fa113dce69d5611f21
1
2
3
4
5
6
7
8
9
10
11
12
import { getCurrentInstance, onUnmounted } from 'vue';
 
import { createContextMenu, destroyContextMenu } from './createContextMenu';
 
export function useContextMenu(authRemove = true) {
  if (getCurrentInstance() && authRemove) {
    onUnmounted(() => {
      destroyContextMenu();
    });
  }
  return [createContextMenu, destroyContextMenu];
}