mirror of
https://github.com/ProjectSegfault/website.git
synced 2025-05-11 20:13:43 +05:30
19 lines
388 B
TypeScript
Executable File
19 lines
388 B
TypeScript
Executable File
import instances from "./instances";
|
|
import type { PageServerLoad } from "./$types";
|
|
|
|
export const load = (({ url }) => {
|
|
const meta = {
|
|
title: "Instances"
|
|
};
|
|
|
|
// If the ?short url query exists, then longUrl is false
|
|
// Every other case is true
|
|
const queryLongUrl = !url.searchParams.has("short");
|
|
|
|
return {
|
|
instances,
|
|
queryLongUrl,
|
|
...meta
|
|
};
|
|
}) satisfies PageServerLoad;
|