Moves the app to TanStack Start with prerendering

Every page is now built as HTML from sitePages.ts, with a catch-all route for
404.html. Hooks that read the browser during render are safe for prerendering.
The script step that keeps the CSP intact follows, so this build still has
inline scripts and is not deployable yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-31 17:58:54 +01:00
co-authored by Claude Opus 5.5
parent 65c850e949
commit c1e90f0768
33 changed files with 746 additions and 269 deletions
@@ -40,12 +40,16 @@ describe('DeferredImage', () => {
});
it('waits for the page load event, even when already in view', async () => {
vi.spyOn(document, 'readyState', 'get').mockReturnValue('interactive');
const readyState = vi
.spyOn(document, 'readyState', 'get')
.mockReturnValue('interactive');
await renderWithProviders(<DeferredImage image={image} />);
const img = screen.getByRole('img', { name: 'Een foto' });
expect(img).not.toHaveAttribute('src');
act(() => {
// The browser is 'complete' by the time the load event fires
readyState.mockReturnValue('complete');
window.dispatchEvent(new Event('load'));
});
expect(img).toHaveAttribute('src', '/foto.jpg');