From e31f6a9a9fe4861b1bdb6b2a3a4cbfb6fd5523fe Mon Sep 17 00:00:00 2001
From: husq <931347610@qq.com>
Date: Tue, 10 Oct 2023 16:41:18 +0800
Subject: [PATCH] 添加默认文字
---
src/utils/common.ts | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/src/utils/common.ts b/src/utils/common.ts
index 26fd977..891e618 100644
--- a/src/utils/common.ts
+++ b/src/utils/common.ts
@@ -10,3 +10,7 @@
lable.click()
URL.revokeObjectURL(lable.href)
}
+
+export const requireImg = (imgPath: string) => {
+ return new URL(`../assets/${imgPath}`, import.meta.url).href
+}
--
Gitblit v1.9.3