Skip to content

Commit 2e260c1

Browse files
committed
CMS-45730 Refactor Standard, [...slug]
1 parent b191041 commit 2e260c1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

templates/alloy-template/src/app/[...slug]/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ export default async function Page({ params }: Props) {
1818
graphUrl: process.env.OPTIMIZELY_GRAPH_URL,
1919
});
2020
const path = `/${slug.join('/')}/`;
21-
const c = await client.getContentByPath(path);
21+
const pageContent = await client.getContentByPath(path);
2222

23-
if (c.length === 0) {
23+
if (pageContent.length === 0) {
2424
notFound();
2525
}
2626

@@ -29,7 +29,7 @@ export default async function Page({ params }: Props) {
2929
{/** Passing down client and currentPath to Footer to fetch dynamic links */}
3030
<Header client={client} currentPath={path} />
3131
<div className="container mx-auto p-10">
32-
<OptimizelyComponent opti={c[0]} />
32+
<OptimizelyComponent opti={pageContent[0]} />
3333
</div>
3434
<Footer client={client} currentPath={path} />
3535
</>

templates/alloy-template/src/components/Standard.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ function Standard({ opti }: StandardPageProps) {
5858
{/* Heading and Description */}
5959
<div className="space-y-4">
6060
<h1
61-
{...pa('title')}
61+
{...pa('heading')}
6262
className="text-4xl font-bold tracking-tight text-gray-900 sm:text-5xl"
6363
>
6464
{opti.heading}

0 commit comments

Comments
 (0)