// /* eslint-disable no-param-reassign */
import store from '@/store';
// import router from '@/router';
// import { openGame } from '@/api/app';
// import { Toast } from 'vant';
// import { ref } from 'vue';

export default (app) => {
  app.config.globalProperties.$getPermission = (val) => {
    // console.log('55555', val);
    // console.log('124564', store.state.user.userInfo);
    if (store.state.user.userInfo.resources.includes(val)) {
      return true
    } else {
      return false
    }
  };
};
