howesteve / elegua

Elegua - a small, reactive PWA router for Svelte
https://elegua.netlify.app/
Apache License 2.0
78 stars 4 forks source link

View transition support #4

Closed ansarizafar closed 1 year ago

ansarizafar commented 1 year ago

Thanks for amazing project. I also hate file based routing and I really like elegua router. Is there any plan to add support for view transitions?

howesteve commented 1 year ago

Glad you like it. What do you mean by "view transitions"? Could you be more specific? Do you mean the new, experimental View Transitions API ?

ansarizafar commented 1 year ago

Yes I mean the new experimental view transitions API. Sveltekit has an open PR and Astro also has a support for view transitions.

howesteve commented 1 year ago

Except if I'm missing something, that API was made to fix the animation problem in non-SPA applications where app state is lost between navigation. In svelte/SPAs, including Elegua, you can just use plain svelte animations and it should work out of the box. So I don't see the need in implementing support for non-SPA animations in a SPA router. Astro and sveltekit implement it because they are more SSR-oriented. Let me know if that makes sense.

howesteve commented 1 year ago

Closing as per lack of reply. Feel free to reopen.