Skip to content

refactor: apply code readability guidelines - #1271

Merged
edenreich merged 1 commit into
mainfrom
refactor/issue-1270-20261117-2100
Nov 17, 2026
Merged

edenreich merged 1 commit into
mainfrom
refactor/issue-1270-20261117-2100

Conversation

@inference-gateway-maintainer

Copy link
Copy Markdown
Contributor

Summary

Applies the Code Readability guidelines from AGENTS.md to the existing source. No behavior change: bun test (byte-for-byte comparison of every generated region) still passes, so generator output is identical.

Generator script and test

  • Removed the file headers from scripts/generate-provider-docs.mjs and its test. The schema env vars (SCHEMA_REPO, SCHEMA_REF, SCHEMA_URL, --schema-file= / SCHEMA_FILE) are now documented in AGENTS.md.
  • Removed the section banner comments and the comment above the import.meta.main guard.
  • Extracted the duplicate-marker check into assertSingleRegion.
  • Shortened the renderAdkProviderTable doc comment to 4 lines.
  • Added AUTH_TYPE_NONE, MIN_SEPARATOR_DASHES, and REGION_PADDING. argValue now slices by the prefix length.
  • startMarker / endMarker are shared between the generator and the test. The test uses REGION_PADDING.length instead of +2 / -1.

Site config and components

  • .vitepress/config.ts: titleTemplate and the author meta use SITE_NAME. Added BRAND_COLOR (theme-color + mermaid border) and OG_IMAGE_WIDTH / OG_IMAGE_HEIGHT. Dropped CLAUDE.md from srcExclude.
  • QuickStartTerminal.vue: NOTHING_COPIED and COPIED_RESET_DELAY_MS constants.
  • FlowDiagram.vue: left the two CSS comments as they are. They explain layout reasons (why the grid spans the band, why the rail stays vertical) that a class name cannot carry.

Markdown semicolons

  • Split every semicolon-joined sentence in prose outside code fences, inline code, and GENERATED:* regions. A semicolon inside parentheses became -, since a period would break the parenthetical. Also fixed a few hand-written config descriptions in configuration.md.
  • The remaining git grep hits are all inside YAML/shell code blocks or a literal CLI output string, which the issue marks as fine.

Validation

bun test, bun run lint:md, bun run format:check, and bun run build all pass locally.

Not done

  • The code snippets in the docs were not run against the tokenless mock gateway. The issue scopes that out as a separate pass.

no docs ticket: internal-only refactor

Closes #1270

Generated with Claude Code

@inference-gateway-releaser

inference-gateway-releaser Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

🗑️ Preview environment destroyed.

@edenreich
edenreich merged commit 5283d1f into main Nov 17, 2026
1 check passed
@edenreich
edenreich deleted the refactor/issue-1270-20261117-2100 branch November 17, 2026 21:47
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.

refactor: apply code readability guidelines

1 participant