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
34 changes: 31 additions & 3 deletions app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,40 @@
import React from 'react';
import type { Metadata } from 'next';
import '@/app/styles/globals.css';
import '@fontsource/rubik/400.css';
import '@fontsource/rubik/700.css';
import '@fontsource/rubik/900.css';

export const metadata = {
title: 'Sentry Error Generator',
description: 'Send sample errors to your Sentry project',
const title = 'Sentry Error Generator';
const description = 'Generate sample errors and performance issues for your Sentry project';

function getBaseUrl() {
if (process.env.VERCEL_PROJECT_PRODUCTION_URL) {
return `https://${process.env.VERCEL_PROJECT_PRODUCTION_URL}`;
}
if (process.env.VERCEL_URL) {
return `https://${process.env.VERCEL_URL}`;
}
return 'http://localhost:3000';
}

const url = getBaseUrl();

export const metadata: Metadata = {
title,
description,
metadataBase: new URL(url),
openGraph: {
title,
description,
siteName: title,
type: 'website',
},
twitter: {
card: 'summary_large_image',
title,
description,
},
};

export default function RootLayout({ children }: { children: React.ReactNode }) {
Expand Down
Binary file added app/opengraph-image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.