feat(ui): UI 骨架与请求集成(sider、tabs、接口面板 sk-key 走 store、手动查询)

t-tabs 用官方 list prop 数据驱动(受控 value + 动态增删语义干净);请求纯手动触发,enabled 门控 + refetch,staleTime Infinity 切 tab 不重发,queryKey ['endpoint', path, skKey] 换 key 即新查询;endpoint-panel 的 sk-key computed 读写 store,切 tab 输入保留。
This commit is contained in:
2026-09-08 00:49:37 +08:00
parent 3f95335651
commit 60ba5b6306
10 changed files with 746 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
import { createApp } from 'vue';
import { VueQueryPlugin } from '@tanstack/vue-query';
import { createPinia } from 'pinia';
import TDesign from 'tdesign-vue-next';
import 'tdesign-vue-next/es/style/index.css';
import App from './App.vue';
import './style.css';
const app = createApp(App);
app.use(createPinia());
// TanStack Query:调试工具语义——不自动重取、失败不重试(详见 endpoint-queries.ts)
app.use(VueQueryPlugin, {
queryClientConfig: {
defaultOptions: {
queries: {
staleTime: Infinity,
gcTime: Infinity,
retry: false,
refetchOnWindowFocus: false,
refetchOnMount: false,
refetchOnReconnect: false,
},
},
},
});
app.use(TDesign);
app.mount('#app');