Skip to content

Fix: Add missing API sections to non-English 4.x documentation - #2076

Merged
bjohansebas merged 3 commits into
expressjs:gh-pagesfrom
Farhan291:fix/non-english-api-sections-issue-2068
Dec 14, 2025
Merged

bjohansebas merged 3 commits into
expressjs:gh-pagesfrom
Farhan291:fix/non-english-api-sections-issue-2068

Conversation

@Farhan291

Copy link
Copy Markdown
Contributor

Description

Fixes broken anchor links in all non-English versions of the 4.x API documentation by adding missing API sections.

Closes #2068

Problem

All non-English language versions only included the app section, causing broken anchor links such as:

  • #req.method ❌
  • #res.send ❌
  • #router ❌
  • #express ❌

Example broken links:

The English version works correctly: https://expressjs.com/en/4x/api.html

Root Cause

The markdown files for non-English versions only included:
{% include api/en/4x/app.md %}
They were missing the other four sections and their anchor tags.

Solution

Added the missing {% include %} statements and anchor tags for all API sections to match the English documentation structure:

  • express.md (Express function)
  • req.md (Request object)
  • res.md (Response object)
  • router.md (Router)

Changes Made

Updated the following files to include all 5 API sections with proper anchor tags:

  • ✅ de/4x/api.md (German)
  • ✅ fr/4x/api.md (French)
  • ✅ es/4x/api.md (Spanish)
  • ✅ it/4x/api.md (Italian)
  • ✅ ja/4x/api.md (Japanese)
  • ✅ pt-br/4x/api.md (Portuguese)
  • ✅ zh-cn/4x/api.md (Chinese Simplified)
  • ✅ zh-tw/4x/api.md (Chinese Traditional)

Testing

  • Tested locally using bundle exec jekyll serve
  • Verified all anchor links work correctly
  • Confirmed structure matches English version
  • Tested multiple languages (de, fr, es)

- Added express, req, res, and router sections to all non-English versions
- Fixed broken anchor links (#req.method, #res.send, #router, etc.)
- Matches structure of English version (en/4x/api.html)
- Affects: de, fr, es, it, ja, pt-br, zh-cn, zh-tw

Closes expressjs#2068
@Farhan291
Farhan291 requested a review from a team as a code owner October 5, 2025 09:43
@netlify

netlify Bot commented Oct 5, 2025 •

Copy link
Copy Markdown

✅ Deploy Preview for expressjscom-preview ready!

Name Link
🔨 Latest commit 7dec254
🔍 Latest deploy log https://app.netlify.com/projects/expressjscom-preview/deploys/693e2d47bfe4dd000899b100
😎 Deploy Preview https://deploy-preview-2076--expressjscom-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions

github-actions Bot commented Oct 5, 2025 •

Copy link
Copy Markdown
Contributor

🚦 Lighthouse Results (Mobile & Desktop)

URL Device Perf A11y Best Practices
/ mobile 🔴 68 🟢 100 🟢 96
/en/blog/posts.html mobile 🟢 98 🟢 96 🟢 96
/en/5x/api.html mobile 🔴 73 🟢 95 🟢 96
/ desktop 🟢 100 🟢 100 🟢 96
/en/blog/posts.html desktop 🟢 100 🟢 96 🟢 92
/en/5x/api.html desktop 🟢 100 🟢 95 🟢 96

@bjohansebas bjohansebas left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks!

@bjohansebas
bjohansebas merged commit c835e5d into expressjs:gh-pages Dec 14, 2025
14 checks 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.

4.x documentation incomplete and anchor links are dead

2 participants