sanifae/src/routes/+layout.js

7 lines
206 B
JavaScript
Raw Normal View History

2023-01-30 16:17:58 -05:00
/** @type {import('./$types').PageLoad} */
export async function load({ fetch, params }) {
const res = await fetch(`/api/session`);
const username = await res.text();
return { username };
}