The async experimental compiler option causes a client-side navigation failure on a weird edge case: When a +layout.svelte exists on a route, client-side navigation to another route causes futher client-side navigation to fail.
Setup:
- repo generated with
sv create svelte.config.jsexperimentalasyncflag is set totrue+layout.svelteis present in a route (/startis used in this example)
To reproduce:
- start the dev server
- open browser
- Follow the links:
/start->/dashboard->/dashboard/test- URL correctly updates to
/dashboard/test, but page does not load
- URL correctly updates to
I've also included a working example: /start-no-layout -> /dashboard -> /dashboard/test
- In this case, the navigation works because there is no
+layout.sveltein the/start-no-layoutroute.
If data-sveltekit-preload-data="hover" is removed from app.html, the navigation works again.