refactor(eslint): ♻️ eslint 规则配置优化

This commit is contained in:
Ray.Hao
2025-05-09 12:56:00 +08:00
parent 3559336701
commit e36f5c813f
8 changed files with 579 additions and 1292 deletions

View File

@@ -124,7 +124,6 @@
</template>
<script setup lang="ts">
import { ref, computed, onMounted, onBeforeUnmount } from "vue";
import router from "@/router";
import { usePermissionStore } from "@/store";
import { isExternal } from "@/utils";
@@ -304,7 +303,9 @@ function loadRoutes(routes: RouteRecordRaw[], parentPath = "") {
name: typeof route.name === "string" ? route.name : undefined,
icon: route.meta.icon,
redirect: typeof route.redirect === "string" ? route.redirect : undefined,
params: route.meta.params ? JSON.parse(JSON.stringify(toRaw(route.meta.params))) : undefined
params: route.meta.params
? JSON.parse(JSON.stringify(toRaw(route.meta.params)))
: undefined,
});
}
});

View File

@@ -242,7 +242,7 @@ export function useStomp(options: UseStompOptions = {}) {
* @param callback 接收到消息时的回调函数
* @returns 返回订阅 id用于后续取消订阅
*/
const subscribe = (destination: string, callback: (message: IMessage) => void): string => {
const subscribe = (destination: string, callback: (_message: IMessage) => void): string => {
if (!client.value) {
return "";
}

View File

@@ -10,7 +10,7 @@ export interface DictMessage {
}
// 字典事件回调类型
export type DictMessageCallback = (message: DictMessage) => void;
export type DictMessageCallback = (_message: DictMessage) => void;
// 全局单例实例
let instance: ReturnType<typeof createDictSyncHook> | null = null;

File diff suppressed because it is too large Load Diff