Skip to content

Commit 18088cc

Browse files
committed
feat: update DatasetsListing to include generateMetadata function and adjust props
1 parent 939d75a commit 18088cc

File tree

1 file changed

+29
-5
lines changed

1 file changed

+29
-5
lines changed
Lines changed: 29 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,33 @@
1-
'use client';
2-
31
import React from 'react';
4-
import { fetchDatasets } from '@/fetch';
2+
3+
import { generatePageMetadata } from '@/lib/utils';
54
import ListingComponent from '../components/ListingComponent';
65

6+
export const generateMetadata = () =>
7+
generatePageMetadata({
8+
title: 'Browse Open Datasets | CivicDataSpace',
9+
description:
10+
'Discover and explore a comprehensive collection of open datasets for research, policy-making, and civic innovation. Filter by sector, format.',
11+
keywords: [
12+
'Open Datasets',
13+
'Data Discovery',
14+
'Public Data',
15+
'Research Data',
16+
'Civic Data',
17+
'Dataset Search',
18+
],
19+
openGraph: {
20+
type: 'website',
21+
locale: 'en_US',
22+
url: `${process.env.NEXT_PUBLIC_PLATFORM_URL}/datasets`,
23+
title: 'Browse Open Datasets | CivicDataSpace',
24+
description:
25+
'Explore thousands of open datasets across sectors like health, education, governance, and environment on CivicDataSpace',
26+
siteName: 'CivicDataSpace',
27+
image: `${process.env.NEXT_PUBLIC_PLATFORM_URL}/og.png`, // from /public/og.png
28+
},
29+
});
30+
731
const DatasetsListing = () => {
832
const breadcrumbData = [
933
{ href: '/', label: 'Home' },
@@ -12,12 +36,12 @@ const DatasetsListing = () => {
1236

1337
return (
1438
<ListingComponent
15-
fetchDatasets={fetchDatasets}
39+
type="dataset"
1640
breadcrumbData={breadcrumbData}
1741
redirectionURL={`/datasets`}
1842
placeholder="Start typing to search for any Dataset"
1943
/>
2044
);
2145
};
2246

23-
export default DatasetsListing;
47+
export default DatasetsListing;

0 commit comments

Comments
 (0)