Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 0 additions & 70 deletions .github/ISSUE_TEMPLATE/ecosystem-submission.yml

This file was deleted.

54 changes: 54 additions & 0 deletions app/ecosystem/[slug]/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
import type { Metadata } from "next";
import { notFound } from "next/navigation";
import EcosystemDetail from "@/components/ecosystem/EcosystemDetail";
import {
getAppBySlug,
getAppSlugs,
renderEcosystemMarkdown,
} from "@/lib/ecosystem";

type Props = {
params: Promise<{ slug: string }>;
};

export async function generateStaticParams() {
return getAppSlugs().map((slug) => ({ slug }));
}

export async function generateMetadata({ params }: Props): Promise<Metadata> {
const { slug } = await params;
try {
const app = getAppBySlug(slug);
return {
title: `${app.name} | Livepeer Ecosystem`,
description: app.description,
openGraph: {
title: `${app.name} | Livepeer Ecosystem`,
description: app.description,
type: "website",
},
twitter: {
card: "summary_large_image",
title: `${app.name} | Livepeer Ecosystem`,
description: app.description,
},
};
} catch {
return { title: "App Not Found — Livepeer Ecosystem" };
}
}

export default async function EcosystemAppPage({ params }: Props) {
const { slug } = await params;

let app;
try {
app = getAppBySlug(slug);
} catch {
notFound();
}

const html = await renderEcosystemMarkdown(app.content);

return <EcosystemDetail app={app} html={html} />;
}
Loading
Loading