Revert "feat(home): link the homepage of every local project in the workspace"
This reverts commit db7724b237.
This commit is contained in:
1 parent
db7724b237
commit
64d4a9e703
9 files changed
+5
-417
No files matched your search
-16
@@ -189,22 +189,6 @@ export async function probePublishApi() {
|
||||
}
|
||||
}
|
||||
|
||||
/** รายชื่อโปรเจคในโฟลเดอร์ข้างเคียง (มีเฉพาะเมื่อเปิดผ่านเซิร์ฟเวอร์หลังบ้านในเครื่องนี้) */
|
||||
export async function fetchLocalProjects() {
|
||||
try {
|
||||
const res = await fetch("api/local-projects", { cache: "no-store" });
|
||||
if (!res.ok) return { available: false, workspace: null, projects: [] };
|
||||
const body = await res.json();
|
||||
return {
|
||||
available: true,
|
||||
workspace: body.workspace || null,
|
||||
projects: Array.isArray(body.projects) ? body.projects : [],
|
||||
};
|
||||
} catch {
|
||||
return { available: false, workspace: null, projects: [] };
|
||||
}
|
||||
}
|
||||
|
||||
export function downloadJson(data) {
|
||||
const payload = toPublishPayload(data);
|
||||
const blob = new Blob([`${JSON.stringify(payload, null, 2)}\n`], {
|
||||
|
||||
Reference in new issue
Block a user