mirror of
https://github.com/fmhy/edit.git
synced 2026-02-19 09:41:17 +11:00
somewhat fix meta
h
This commit is contained in:
parent
d3d5858b13
commit
2b65bc9332
7 changed files with 42 additions and 47 deletions
|
|
@ -40,7 +40,7 @@ export default defineLoader({
|
|||
const obj = Object.fromEntries(
|
||||
[...guides.entries()].map((entry, index) => [index.toString(), entry]),
|
||||
);
|
||||
await writeFile("./guides.json",JSON.stringify(obj, null, 4), "")
|
||||
return await readFile("./guides.json", { encoding: "utf-8"})
|
||||
await writeFile("./guides.json", JSON.stringify(obj, null, 4), "utf-8");
|
||||
return JSON.parse(await readFile("./guides.json", { encoding: "utf-8" })) as Data;
|
||||
},
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue