mirror of
https://gitee.com/butubb8/blowfish.git
synced 2025-12-05 14:17:50 +08:00
refactor(repo-card): use iife and async loading
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
async function fetchRepo() {
|
||||
(async () => {
|
||||
const script = document.currentScript;
|
||||
const repoURL = script?.getAttribute("data-repo-url");
|
||||
const repoId = script?.getAttribute("data-repo-id");
|
||||
@@ -54,6 +54,4 @@ async function fetchRepo() {
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
}
|
||||
|
||||
fetchRepo();
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user