export default defineNuxtPlugin((nuxtApp) => { const store = useStore(); const { $getapi, $readyapi } = nuxtApp; const connlist = $readyapi([ "common", "tablesetting", "datatype", "filtertype", "sorttype", "settingtype", "settingclass", "settingchoice", "filterchoice", "colorchoice", "sharechoice", "menuchoice", "textalign", "placement", "colorscheme", ]); const notReadyConns = connlist.filter((v) => !v.ready); async function getReady() { await $getapi(notReadyConns); store.ready = true; } if (notReadyConns.length > 0) getReady(); });