svelte-society/sveltesociety.dev

Anchor links to site are broken

benmccann opened this issue · 5 comments

Anchors don't work. E.g. if you go to https://kit.svelte.dev/docs/integrations and click "available preprocessors" it will take you to https://sveltesociety.dev/tools#preprocessors, but then that doesn't scroll to the correct location and just stays at the top of the page

It's probably because the data to display is only set after the search event is dispatched: https://github.com/svelte-society/sveltesociety.dev/blob/staging/src/routes/searchableJson.svelte#L53

Fixed here: 3877a1e

Pushed without a review to get the site working again before the special episode of Svelte Radio on Dec 14

I thought I'd fixed this, but it doesn't seem to have been fixed actually

Any help would be appreciated! I probably won't be able to get back to this for the rest of the year

Probably because the page at server side is empty.
Seem like the SSR can't find all the items


curl https://sveltesociety.dev/tools#preprocessors

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />

<!-- ... -->

<a href="/help/submitting?type=tool" class="submit">Submit a tool</a></div>
<input class="searchbar" type="text" placeholder="Search for tools..." value="">
<span class="searchbar-count">0 results</span></section>
<hr>
<section slot="items"></section></main>

<!-- ... -->

many thanks to @gtm-nayan for figuring out this was fixed, but not deployed due to a broken build!