🧑🔧 Updated https://austrian-web-dev-companies.pages.dev/ a bit more, learned how bind:group works with #Svelte v5 $state.
🚉 Next stop: Adding pagination & URL params.
=> More informations about this toot | More toots from mandrasch@social.tchncs.de
After getting help on Svelte Discord, I integrated a rather interesting $effect pattern to load my $state from URL parameters (thx to l3t!) + added pagination ✅ Guess I have to get used to $effect in #Svelte v5. https://github.com/mandrasch/austrian-web-dev-companies/blob/68a4caa8435df0b8e5502501baa6fc153170171f/src/routes/%2Bpage.svelte#L51
🚉 Next stop: Scroll to results div after pagination click.
=> More informations about this toot | More toots from mandrasch@social.tchncs.de
@mandrasch Next step could be
href="/list/?page=3#results"
Possibly with the scroll-margin-top CSS property set
=> More informations about this toot | More toots from matthiou@mastodon.social
@matthiou thx for reply! I gave it a try with afterNavigate
/ beforeNavigate
already and element.scrollIntoView() - but I had a conflicht with $effect https://github.com/mandrasch/austrian-web-dev-companies/blob/68a4caa8435df0b8e5502501baa6fc153170171f/src/routes/%2Bpage.svelte#L26 Currently not sure if I even should use afterNavigate
/ beforeNavigate
in Svelte v5 or if this should all be handled by $effect.
=> More informations about this toot | More toots from mandrasch@social.tchncs.de
text/gemini
This content has been proxied by September (3851b).