chore: 重构项目结构
This commit is contained in:
@@ -10,14 +10,14 @@ const commentsRoot = ref(null);
|
||||
onMounted(async () => {
|
||||
if (!commentsRoot.value || typeof window === "undefined") return;
|
||||
|
||||
const apiBaseUrl = "https://cwd-comments-api.anghunk.workers.dev";
|
||||
const apiBaseUrl = "https://cwd-api.anghunk.workers.dev";
|
||||
|
||||
if (!apiBaseUrl) return;
|
||||
|
||||
if (!window.CWDComments) {
|
||||
await new Promise((resolve, reject) => {
|
||||
const script = document.createElement("script");
|
||||
script.src = "https://cwd-comments.zishu.me/cwd-comments.js";
|
||||
script.src = "https://cwd.zishu.me/cwd.js";
|
||||
script.async = true;
|
||||
script.onload = () => resolve();
|
||||
script.onerror = (e) => reject(e);
|
||||
|
||||
@@ -11,7 +11,7 @@ export default defineConfig({
|
||||
'link',
|
||||
{
|
||||
rel: 'icon',
|
||||
href: 'https://github.com/anghunk/cwd-comments/blob/main/icon.png?raw=true',
|
||||
href: 'https://github.com/anghunk/cwd/blob/main/icon.png?raw=true',
|
||||
},
|
||||
],
|
||||
],
|
||||
@@ -23,10 +23,10 @@ export default defineConfig({
|
||||
label: 'On this page',
|
||||
},
|
||||
editLink: {
|
||||
pattern: 'https://github.com/anghunk/cwd-comments/blob/main/docs/:path',
|
||||
pattern: 'https://github.com/anghunk/cwd/blob/main/docs/:path',
|
||||
text: '在 GitHub 上编辑此页面',
|
||||
},
|
||||
socialLinks: [{ icon: 'github', link: 'https://github.com/anghunk/cwd-comments' }],
|
||||
socialLinks: [{ icon: 'github', link: 'https://github.com/anghunk/cwd' }],
|
||||
|
||||
lastUpdated: true,
|
||||
lastUpdatedText: '最后更新于',
|
||||
|
||||
Reference in New Issue
Block a user