Skip to content

Remove docs build lint and Browserslist warnings - #1909

Open
marcleblanc2 wants to merge 3 commits into
mainfrom
build/lint-warnings-and-caniuse
Open

Remove docs build lint and Browserslist warnings#1909
marcleblanc2 wants to merge 3 commits into
mainfrom
build/lint-warnings-and-caniuse

Conversation

@marcleblanc2

@marcleblanc2 marcleblanc2 commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Task 6b of the Vercel audit tracked in #1905. Rebased on current main.

What was warning

pnpm build printed one Browserslist warning and six ESLint warnings on every deploy.

  • Browserslist: caniuse-lite is outdated — refreshed the caniuse-lite and baseline-browser-mapping entries in pnpm-lock.yaml. Lockfile only.
  • @next/next/no-img-element in Logo.tsx, LinkCards.tsx, ProductCards.tsx, ZoomableImage.tsx, api/og/[...path]/route.tsx — kept the native <img> with a one-line disable and reason at each site. next/image would route every image through Vercel Image Optimization (billed), needs known dimensions that arbitrary MDX images don't have, and Satori (OG images) cannot render next/image at all.
  • react-hooks/exhaustive-deps in ContentTabs.jsx — moved the URL-to-tab selection into the effect and listed its inputs. Note: Stop bundling the docs corpus into the client JS (24 MB chunk) #1915 deletes this file outright (it's unused); whichever PR merges second needs a trivial rebase that keeps the deletion.

README markdownlint findings (second commit)

markdownlint-cli2 README.md reported 49 findings: 27 long lines, 12 list markers padded to - (stale Prettier 2 output; Prettier 3 in this repo writes - ), table pipes without spaces, an MDX example fence with no language, and two images with no alt text. Prose is wrapped at 80 columns, the file is run through pnpm format's Prettier config, and two lines that cannot wrap (a table cell, a long link inside a code block) are shortened. Wording is otherwise unchanged apart from one "relevant relevant" typo.

AGENTS.md (third commit)

Same wrapping and Prettier treatment. Two content changes to flag: the nested link-check bullets are now a flat ### Links list (Prettier indents nested lists by 4, markdownlint wants 2) with the long external-check command in a sh fence; and the AI Chat Integration / Important Notes sections are replaced by a two-line note, because they described a runLLM widget that #1536 removed (rg -i runllm src/ finds nothing).

Verification

  • pnpm install --frozen-lockfile, pnpm lint✔ No ESLint warnings or errors
  • pnpm build → no Browserslist warning; npx tsc --noEmit clean
  • npx markdownlint-cli2 README.md AGENTS.md → 0 issues; prettier --check README.md AGENTS.md → clean

How to review

Read the seven eslint-disable comments and check the reason on each makes sense; the lockfile diff is two version bumps. For the README, git diff --word-diff shows only the wrapping and the small edits listed above.

@vercel

vercel Bot commented Sep 11, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated
sourcegraph-docs Ready Ready Preview Sep 11, 2026 11:08am UTC

Request Review

@marcleblanc2
marcleblanc2 force-pushed the build/lint-warnings-and-caniuse branch from fbb32fc to 4501910 Compare September 11, 2026 10:20
@marcleblanc2
marcleblanc2 marked this pull request as ready for review September 11, 2026 10:20
Wrap prose at 80 columns, run Prettier (single-space list markers,
aligned table), add a language to the MDX example fence and alt text
to both images, and shorten the two lines that could not wrap.

Amp-Thread-ID: https://ampcode.com/threads/T-01a08e2d-682f-75dd-a050-cb9bf8888dac
Co-authored-by: Amp <amp@ampcode.com>
Wrap the build commands at 80 columns and move the link-check guidance
into its own flat list so Prettier and markdownlint agree on indentation.
The AI Chat Integration and Important Notes sections described a runLLM
widget removed in #1536; replace them with a two-line note.

Amp-Thread-ID: https://ampcode.com/threads/T-01a08e2d-682f-75dd-a050-cb9bf8888dac
Co-authored-by: Amp <amp@ampcode.com>
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