Files
SnowLuma/.pnpm-store/v11/files/18/3b1c052ad3d33cbbbbab1f3a15d8b541b6424bf8aa6b99eadbaaec6df4ad3ac44c0fd28f480d0af2573cc08db4faf1f0aed8944be763ccea0e40fbe3d84f9e
TanTan 2a69b23b47
Dev Build / cleanup (push) Waiting to run
Dev Build / typecheck (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:27:07 +08:00

30 lines
1000 B
Plaintext

import { toSSG as toSSG$1 } from "../../helper/ssg/ssg.js";
import "../../helper/ssg/index.js";
//#region src/adapter/deno/ssg.ts
/**
* @experimental
* `denoFileSystemModule` is an experimental feature.
* The API might be changed.
* @deprecated `hono/deno` will be removed in v5. Install `@hono/deno` and import from there instead.
*/
const denoFileSystemModule = {
writeFile: async (path, data) => {
const uint8Data = typeof data === "string" ? new TextEncoder().encode(data) : new Uint8Array(data);
await Deno.writeFile(path, uint8Data);
},
mkdir: async (path, options) => {
return Deno.mkdir(path, { recursive: options?.recursive ?? false });
}
};
/**
* @experimental
* `toSSG` is an experimental feature.
* The API might be changed.
* @deprecated `hono/deno` will be removed in v5. Install `@hono/deno` and import from there instead.
*/
const toSSG = async (app, options) => {
return toSSG$1(app, denoFileSystemModule, options);
};
//#endregion
export { denoFileSystemModule, toSSG };