Skip to content

Commit 971b558

Browse files
committed
refactor: use useBaseUrl for demo iframe src in Examples page
1 parent 43ec316 commit 971b558

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

website/src/pages/examples.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1+
import useBaseUrl from '@docusaurus/useBaseUrl';
12
import Layout from '@theme/Layout';
23

34
export default function ExamplesPage() {
5+
const demoUrl = useBaseUrl('/demos/index.html');
6+
47
return (
58
<Layout title="Examples" description="Interactive classy-store examples">
69
<iframe
7-
src="/classy-store/demos/index.html"
10+
src={demoUrl}
811
title="Classy Store Interactive Examples"
912
style={{width: '100%', height: 'calc(100vh - 60px)', border: 'none'}}
1013
/>

0 commit comments

Comments
 (0)