Skip to content

Commit 1fe1f86

Browse files
fix(og): Satori needs display:flex on divs with multiple children
Node runtime's Satori is stricter than edge. Divs containing text + <br> + <span> were untyped and broke prerender. Replaced with flex column + two <span> children. Verified locally with `next build` — all four OG routes prerender cleanly now. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent b9ad2c0 commit 1fe1f86

4 files changed

Lines changed: 13 additions & 15 deletions

File tree

src/app/opengraph-image.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,19 @@ export default function OGImage() {
3838
<div style={{ display: "flex", flexDirection: "column", gap: "20px" }}>
3939
<div
4040
style={{
41+
display: "flex",
42+
flexDirection: "column",
4143
color: "#ffffff",
4244
fontSize: "72px",
4345
fontWeight: "800",
4446
lineHeight: "1.0",
4547
letterSpacing: "-0.04em",
4648
}}
4749
>
48-
Everything you need
49-
<br />
50+
<span>Everything you need</span>
5051
<span style={{ color: "#2563EB" }}>to ship with AI.</span>
5152
</div>
52-
<div style={{ color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
53+
<div style={{ display: "flex", color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
5354
Prompts · 10-step workflow · fixes · deep-dives · free &amp; open
5455
</div>
5556
</div>

src/app/vs-books/opengraph-image.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,11 @@ export default function OGImage() {
2727
</div>
2828

2929
<div style={{ display: "flex", flexDirection: "column", gap: "20px" }}>
30-
<div style={{ color: "#ffffff", fontSize: "72px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31-
vibeprompt vs.
32-
<br />
30+
<div style={{ display: "flex", flexDirection: "column", color: "#ffffff", fontSize: "72px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31+
<span>vibeprompt vs.</span>
3332
<span style={{ color: "#2563EB" }}>the vibe coding books.</span>
3433
</div>
35-
<div style={{ color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
34+
<div style={{ display: "flex", color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
3635
How the free web-native option compares to Gene Kim & Yegge and Smykowski.
3736
</div>
3837
</div>

src/app/vs-tools/opengraph-image.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,11 @@ export default function OGImage() {
2727
</div>
2828

2929
<div style={{ display: "flex", flexDirection: "column", gap: "20px" }}>
30-
<div style={{ color: "#ffffff", fontSize: "70px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31-
vibeprompt vs.
32-
<br />
30+
<div style={{ display: "flex", flexDirection: "column", color: "#ffffff", fontSize: "70px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31+
<span>vibeprompt vs.</span>
3332
<span style={{ color: "#2563EB" }}>the tools.</span>
3433
</div>
35-
<div style={{ color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
34+
<div style={{ display: "flex", color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
3635
Replit, Lovable, Bolt, Cursor, Claude Code, v0 — honest comparison.
3736
</div>
3837
</div>

src/app/workflow/opengraph-image.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,11 @@ export default function OGImage() {
2727
</div>
2828

2929
<div style={{ display: "flex", flexDirection: "column", gap: "20px" }}>
30-
<div style={{ color: "#ffffff", fontSize: "72px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31-
From idea to shipped,
32-
<br />
30+
<div style={{ display: "flex", flexDirection: "column", color: "#ffffff", fontSize: "72px", fontWeight: "800", lineHeight: "1.0", letterSpacing: "-0.04em" }}>
31+
<span>From idea to shipped,</span>
3332
<span style={{ color: "#2563EB" }}>in 10 steps.</span>
3433
</div>
35-
<div style={{ color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
34+
<div style={{ display: "flex", color: "#71717a", fontSize: "24px", fontWeight: "400" }}>
3635
Interactive checklist. Progress saves locally. Pick up where you left off.
3736
</div>
3837
</div>

0 commit comments

Comments
 (0)