fix(/blog/+server.ts): Make it prerender false, so I can carry on using searchParams

This commit is contained in:
Thomas 2025-03-16 12:38:06 +00:00
parent 45c6de2adf
commit a2a2b6a0e0
No known key found for this signature in database

View file

@ -2,7 +2,12 @@ import { BlogController } from '$lib/blog/BlogController.js';
import type { Load } from '@sveltejs/kit'; import type { Load } from '@sveltejs/kit';
import { differenceInCalendarDays, getYear } from 'date-fns'; import { differenceInCalendarDays, getYear } from 'date-fns';
export const prerender = true; /**
* TODO: Return this to `true`, which will mean moving the `tag` searchParams from this route
* to another, e.g. /blog/tagged/:tag, however in the interest of moving quickly, I'm leaving
* it here for now. 2025-03-16
*/
export const prerender = false;
export const load: Load = async ({ params, url }) => { export const load: Load = async ({ params, url }) => {
const controller = await BlogController.singleton(); const controller = await BlogController.singleton();