import type { PageLoad } from "./$types";

export const load: PageLoad = (event) => {
	const query = event.url.searchParams.get("q") ?? "";
	const type = event.url.searchParams.get("type") === "code" ? "code" : "repo";

	return { query, type };
};
