diff --git a/packages/react-sdk/src/app/custom-components/shared/remix-link.tsx b/packages/react-sdk/src/app/custom-components/shared/remix-link.tsx index 427c0f8d49..e5aef71851 100644 --- a/packages/react-sdk/src/app/custom-components/shared/remix-link.tsx +++ b/packages/react-sdk/src/app/custom-components/shared/remix-link.tsx @@ -12,7 +12,7 @@ export const wrapLinkComponent = (BaseLink: LinkComponent) => { const href = usePropUrl(getInstanceIdFromComponentProps(props), "href"); if (href?.type === "page") { - let to = href.page.path; + let to = href.page.path === "" ? "/" : href.page.path; if (href.hash !== undefined) { to += `#${href.hash}`; } diff --git a/packages/react-sdk/src/components/link.tsx b/packages/react-sdk/src/components/link.tsx index 2418af3138..50fed5192f 100644 --- a/packages/react-sdk/src/components/link.tsx +++ b/packages/react-sdk/src/components/link.tsx @@ -23,7 +23,7 @@ export const Link = forwardRef((props, ref) => { switch (href?.type) { case "page": - url = href.page.path; + url = href.page.path === "" ? "/" : href.page.path; if (href.hash !== undefined) { url += `#${href.hash}`; }