Skip to content

docs: rewrite the docs from scratch in 12 pages - #46

Merged
vite-hub[bot] merged 2 commits into
mainfrom
docs/from-scratch
Nov 6, 2026
Merged

vite-hub[bot] merged 2 commits into
mainfrom
docs/from-scratch

Conversation

@onmax

@onmax onmax commented Nov 6, 2026

Copy link
Copy Markdown
Owner

The docs had 17 pages for one composable and six options. Valibot, Zod and ArkType each had a page with the same schema in different syntax. The env-spec page read like a spec for people writing adapters ("Framework adapters must normalize..."), not for someone filling in a .env.example. Several pages said the same thing twice.

This rewrites them from scratch in 12 pages, using evlog's docs and their writing rules as the model: each page opens on what goes wrong, shows the fix, and says what it costs.

  • guide/: Introduction, Installation (Valibot, Zod and ArkType as tabs), Validation, Environment variables, Types, .env.example as schema, ESLint, Nitro, Migrate to ViteHub Env
  • reference/: Configuration (options table, useSafeRuntimeConfig() signature, entry points) and env-spec syntax
  • /schemas/*, /integrations/* and /guide/configuration redirect to their new pages. README links updated. /guide/migrate-to-vitehub-env, which src/module.ts links to, keeps its URL.

I took the error messages from real runs of the validators instead of copying the old ones. While checking claims against the source I found one the old docs got wrong. An inline Zod .refine()/.superRefine() or ArkType .narrow()/.pipe() converts to JSON Schema without an error, and the server-start check then skips it. Valibot transform/check and Zod .transform() fail the build instead. The Environment variables page now has a table for this.

I haven't built the docs locally. The Vercel preview on this PR is the render check.

Fold the Valibot, Zod and ArkType pages into tabs on Installation, move ESLint into the guide, and replace the env-spec profile page with a reference for app developers. Redirect the removed routes.
@vercel

vercel Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
nuxt-safe-runtime-config Ready Ready Preview Nov 6, 2026 11:25am UTC

@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-06T11:06:30.530020Z
We couldn’t complete this review. Comment @codex review to try again.
09b73ff PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@pkg-pr-new

pkg-pr-new Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/nuxt-safe-runtime-config@46

commit: a6c2fdb

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

Two compatibility and runtime-behavior claims should be corrected before merging.

Reviewed changes Reviewed the complete documentation rewrite and route migration, including all user-facing API, configuration, validation, type-generation, env-schema, ESLint, Nitro, and migration claims.

  • Guide consolidation — Replaces the schema-library and integration sections with a 12-page guide/reference structure and redirects the old routes.
  • Installation and usage — Adds Valibot, Zod, and ArkType tabs, typed composable examples, and deployment guidance.
  • Validation behavior — Reframes build and server-start validation, coercion, schema modules, error handling, and request-scoped config.
  • Schema and tooling reference — Documents generated types, .env.example syntax, module options, ESLint, standalone Nitro, and ViteHub Env migration.
  • Render verification — pnpm --dir docs build completes successfully.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-5.6-sol | 𝕏

Comment thread docs/content/1.guide/2.installation.md Resolved
Comment thread docs/content/index.md Resolved
@vite-hub

vite-hub Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor
Session Status Started Duration
Pending Completed Not started —
View session Completed 2026-11-06T11:15:34.715Z 8m 55s

Latest result

Pull request merged.

Final answers

Session

Pull request merged.

View session

Pushed a6c2fdb and resolved Pullfrog P1 Zod compatibility and P2 async-startup documentation findings. Both reproduced before repair. node verify-zod.mjs after passed snippet typechecks and URL cases on Zod 3.24.0/4.6.7; node verify-runtime.mjs after confirmed synchronous startup errors and asynchronous request rejection. git diff --check passed. ESLint excludes docs; its attempted command was interrupted during automatic installation. Host dependency setup rejected pre-existing minimumReleaseAgeExcludePrune; full validation awaits CI.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes Reviewed the follow-up documentation fixes since the prior Pullfrog review.

  • Restored Zod compatibility — Replaced the Zod 4-only z.url() calls with z.string().url(), matching the documented Zod 3.24 minimum.
  • Qualified runtime failures — Updated the landing page to distinguish synchronous schemas that stop startup from asynchronous schemas whose failures surface on requests.
  • Rechecked the docs build — pnpm --dir docs build completes successfully on the updated head, with only non-fatal dependency and bundler warnings.

Pullfrog  | View workflow run | Using gpt-5.6-sol | 𝕏

@vite-hub
vite-hub Bot merged commit 07253d3 into main Nov 6, 2026
6 checks passed
@github-actions github-actions Bot mentioned this pull request Nov 6, 2026

This branch was successfully deployed

1 active deployment
Preview — a6c2fdbf Deployed Nov 6, 2026 by vercel[bot]
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.

1 participant