Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f3357dd

Browse files
committed
fix: opengraph image not showing
1 parent c6aa605 commit f3357dd

File tree

4 files changed

+26
-8
lines changed

4 files changed

+26
-8
lines changed

src/app/components/protos/hero-section.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -381,6 +381,10 @@ import { Button } from '../ui/button';
381381

382382
/* eslint-disable */
383383

384+
/* eslint-disable */
385+
386+
/* eslint-disable */
387+
384388
function TypingAnimation() {
385389
const el = useRef(null);
386390

src/app/components/reusables/code/code-block.tsx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,16 @@ import CopyButton from './copy-code';
148148

149149
// react-syntax-highlighter has no types
150150

151+
/* eslint-disable */
152+
// @ts-nocheck
153+
154+
// react-syntax-highlighter has no types
155+
156+
/* eslint-disable */
157+
// @ts-nocheck
158+
159+
// react-syntax-highlighter has no types
160+
151161
/* eslint-disable */
152162
// @ts-nocheck
153163
SyntaxHighlighter.registerLanguage('rust', rust);

src/app/opengraph-image.tsx

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,18 @@ export const contentType = 'image/png';
1010
export default async function Image() {
1111
return new ImageResponse(
1212
(
13-
<div className="text-[128px] dimmed-4 gradient-bg w-full h-full flex items-center justify-center">
14-
<span>A S H G W</span>
13+
<div
14+
className="gradient-bg"
15+
style={{
16+
fontSize: 128,
17+
width: '100%',
18+
height: '100%',
19+
display: 'flex',
20+
alignItems: 'center',
21+
justifyContent: 'center',
22+
}}
23+
>
24+
<span className="dimmed-4">A S H G W</span>
1525
</div>
1626
),
1727
{

src/lib/mdx/content.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ async function readMDXFile(filePath: string): Promise<Optional<MDXData>> {
3232
}
3333
}
3434
async function getMDXData(dir: string): Promise<Optional<PostData[]>> {
35-
console.log('Invoked all mdx data from: ' + dir);
3635
const mdxFiles = await getMDXFiles(dir);
3736
if (mdxFiles === null) {
3837
return null;
@@ -53,9 +52,6 @@ async function getMDXData(dir: string): Promise<Optional<PostData[]>> {
5352
export async function getBlogPosts(
5453
blogDirectory: string = BLOG_CONTENT_PATH
5554
): Promise<Optional<PostData[]>> {
56-
console.log(
57-
'Invoked all blog posts from: ' + path.join(process.cwd(), blogDirectory)
58-
);
5955
return getMDXData(path.join(process.cwd(), blogDirectory));
6056
}
6157

@@ -74,7 +70,6 @@ export async function getBlogPost(slug: string): Promise<Optional<PostData>> {
7470
(p) => p?.filename === slug
7571
);
7672
if (blogPost === undefined) {
77-
console.log('No blog post matched the given slug');
7873
return null;
7974
}
8075
return blogPost;
@@ -91,7 +86,6 @@ export async function getBusinessPost(
9186
(p) => p?.filename === slug
9287
);
9388
if (blogPost === undefined) {
94-
console.log('No blog post matched the given slug');
9589
return null;
9690
}
9791
return blogPost;

0 commit comments

Comments
 (0)