Skip to content

Commit c4e348e

Browse files
authored
Revert "Expose sveltekit goto function to window (#439)" (#444)
This reverts commit ee4caf7.
1 parent 1f95bc7 commit c4e348e

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

src/doc_builder/convert_md_to_mdx.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ def convert_md_to_mdx(md_text, page_info):
3131
return (
3232
"""<script lang="ts">
3333
import {onMount} from "svelte";
34-
import { goto } from '$app/navigation';
3534
import Tip from "$lib/Tip.svelte";
3635
import Youtube from "$lib/Youtube.svelte";
3736
import Docstring from "$lib/Docstring.svelte";
@@ -59,7 +58,6 @@ def convert_md_to_mdx(md_text, page_info):
5958
onMount(() => {
6059
const urlParams = new URLSearchParams(window.location.search);
6160
fw = urlParams.get("fw") || "pt";
62-
window.hfDocGoto = goto;
6361
});
6462
</script>
6563
<svelte:head>

tests/test_convert_md_to_mdx.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ def test_convert_md_to_mdx(self):
3333
md_text = "Lorem ipsum dolor sit amet, consectetur adipiscing elit"
3434
expected_conversion = """<script lang="ts">
3535
import {onMount} from "svelte";
36-
import { goto } from '$app/navigation';
3736
import Tip from "$lib/Tip.svelte";
3837
import Youtube from "$lib/Youtube.svelte";
3938
import Docstring from "$lib/Docstring.svelte";
@@ -61,7 +60,6 @@ def test_convert_md_to_mdx(self):
6160
onMount(() => {
6261
const urlParams = new URLSearchParams(window.location.search);
6362
fw = urlParams.get("fw") || "pt";
64-
window.hfDocGoto = goto;
6563
});
6664
</script>
6765
<svelte:head>

0 commit comments

Comments
 (0)