File tree Expand file tree Collapse file tree 1 file changed +2
-9
lines changed
apps/svelte.dev/src/routes/docs/[topic]/[...path] Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Original file line number Diff line number Diff line change 99 import { goto } from ' $app/navigation' ;
1010 import { escape_html } from ' $lib/utils/escape' ;
1111 import { page } from ' $app/state' ;
12+ import { get_topic_title } from ' $lib/server/llms' ;
1213
1314 let { data } = $props ();
1415
2223 return ` https://github.com/sveltejs/${name }/edit/main/documentation/${link } ` ;
2324 });
2425
25- // Map topic slug to readable title
26- const topicTitles: Record <string , string > = {
27- svelte: ' Svelte' ,
28- kit: ' SvelteKit' ,
29- cli: ' Svelte CLI' ,
30- mcp: ' Svelte MCP'
31- };
32-
33- const topicTitle = $derived (topicTitles [page .params .topic ] || ' Svelte' );
26+ const topicTitle = $derived (get_topic_title (page .params .topic ));
3427
3528 onMount (() => {
3629 // hash was lowercase in v4 docs and varying case in v5 docs
You can’t perform that action at this time.
0 commit comments