feat: shared links custom URL (#19999)
* feat: custom url for shared links * feat: use a separate route and query param --------- Co-authored-by: Jason Rasmussen <jason@rasm.me>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
<script lang="ts">
|
||||
import SharedLinkErrorPage from '$lib/components/pages/SharedLinkErrorPage.svelte';
|
||||
</script>
|
||||
|
||||
<SharedLinkErrorPage />
|
||||
@@ -0,0 +1,12 @@
|
||||
<script lang="ts">
|
||||
import SharedLinkPage from '$lib/components/pages/SharedLinkPage.svelte';
|
||||
import type { PageData } from './$types';
|
||||
|
||||
type Props = {
|
||||
data: PageData;
|
||||
};
|
||||
|
||||
let { data }: Props = $props();
|
||||
</script>
|
||||
|
||||
<SharedLinkPage {data} />
|
||||
@@ -0,0 +1,4 @@
|
||||
import { loadSharedLink } from '$lib/utils/shared-links';
|
||||
import type { PageLoad } from './$types';
|
||||
|
||||
export const load = (async ({ params, url }) => loadSharedLink({ params, url })) satisfies PageLoad;
|
||||
Reference in New Issue
Block a user