Website Structure

This commit is contained in:
supalerk-ar66 2026-01-13 10:46:40 +07:00
parent 62812f2090
commit 71f0676a62
22365 changed files with 4265753 additions and 791 deletions

View file

@ -0,0 +1,22 @@
import "#nitro-internal-pollyfills";
import { useNitroApp } from "nitropack/runtime";
import { normalize } from "pathe";
const nitroApp = useNitroApp();
async function cli() {
const url = process.argv[2] || "/";
const debug = (label, ...args) => console.debug(`> ${label}:`, ...args);
const r = await nitroApp.localCall({ url });
debug("URL", url);
debug("StatusCode", r.status);
debug("StatusMessage", r.statusText);
for (const header of Object.entries(r.headers)) {
debug(header[0], header[1]);
}
console.log("\n", r.body?.toString());
}
if (process.argv.some((arg) => import.meta.url.includes(normalize(arg)))) {
cli().catch((error) => {
console.error(error);
process.exit(1);
});
}