Skip to content

fix: bump fumadocs-core/ui/openapi to fix a hydration bug - #69

Merged
trichardswp merged 1 commit into
mainfrom
corpus-build-patch-fix
Oct 13, 2026
Merged

trichardswp merged 1 commit into
mainfrom
corpus-build-patch-fix

Conversation

@lhagenWP

@lhagenWP lhagenWP commented Oct 13, 2026 •

Copy link
Copy Markdown
Collaborator

Why

Every reference page logs a React hydration error: fumadocs-openapi's
Authorization selector renders a single security scheme's label
(built as a <div>) inside a <p> tag, which is invalid HTML. The
fix landed upstream in fumadocs-openapi 10.10.3, but that release
needs fumadocs-core and fumadocs-ui >=16.9.0, which this repo didn't
have, so a direct bump of fumadocs-openapi alone breaks the build on
a missing export.

What Changed

Bumps fumadocs-core and fumadocs-ui to 16.9.3 and fumadocs-openapi to
10.10.3, all within already-declared semver ranges. tailwindcss needed
a matching bump too — fumadocs-ui's bundled CSS now uses the
inset-s-* logical-property utility, added in Tailwind 4.2.0, and
bun.lock had tailwindcss pinned below that.

Two usage sites needed fixing for the version jump:

  • A locally-forked BaseLayoutProps type
    (src/components/layout/shared) had drifted from upstream's
    now-wider NavOptions.title type. layout.shared.tsx now points at
    the local type it's actually rendered through, instead of
    upstream's.
  • fumadocs-openapi's SchemaMap type isn't exported, so the OpenAPI
    client's input function is now typed off createOpenAPI's own
    signature rather than a guessed private type name.

Context

An earlier PR patched fumadocs-openapi 10.1.1 directly with bun patch to carry just the hydration fix. That broke the Nix derivation
that builds this repo's generated corpus: bun install --backend=copyfile populates node_modules from a read-only bun2nix
cache, and bun's patchedDependencies step needs to write into the
file it's patching, so it failed with EACCES. Stripping
patchedDependencies before install (mirroring what bun2nix's own
hook already does for this exact situation) worked, but means one
install step behaves differently depending on who's running it — not
worth owning as a permanent pattern when the library already ships
the fix two versions up. This PR takes the clean upgrade instead and
removes the patch entirely.

fumadocs-openapi's Authorization selector renders a single security
scheme's label (built as a <div>) inside a <p> tag, which is invalid
HTML and logs a hydration error on every reference page. The fix
landed upstream in 10.10.3, but that release needs fumadocs-core and
fumadocs-ui >=16.9.0, which this repo didn't have.

A prior attempt patched 10.1.1 directly with `bun patch`. That broke
under Nix: `bun install --backend=copyfile` populates node_modules
from a read-only bun2nix cache, and bun's patchedDependencies step
needs to write into the file it's patching, so the Nix derivation
that builds this repo's generated corpus failed with EACCES applying
the patch. Patching around that gap (stripping patchedDependencies
before install, the way bun2nix's own hook already does for exactly
this case) was the next thing tried, and is a legitimate pattern, but
means one install step behaves differently depending on who's running
it --- a correctness surface not worth owning when the library already
ships the fix two versions up.

Bumps fumadocs-core and fumadocs-ui to 16.9.3 (the lowest patch on the
required minor) and fumadocs-openapi to 10.10.3, all within already-
declared semver ranges. tailwindcss needed a matching bump too:
fumadocs-ui's bundled CSS now uses the `inset-s-*` logical-property
utility, added in Tailwind 4.2.0, and bun.lock had tailwindcss pinned
below that. Two usage sites needed fixing for the version jump: a
locally-forked `BaseLayoutProps` type
(`src/components/layout/shared`) had drifted from upstream's now-wider
`NavOptions.title` type, so `layout.shared.tsx` points at the local
type it's actually rendered through instead of upstream's; and
fumadocs-openapi's `SchemaMap` type isn't exported, so the OpenAPI
client's `input` function is now typed off `createOpenAPI`'s own
signature rather than a guessed private name.
@lhagenWP
lhagenWP force-pushed the corpus-build-patch-fix branch from 48a1c96 to 2088241 Compare October 13, 2026 22:31
@trichardswp
trichardswp merged commit ceb35e7 into main Oct 13, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants