Show the whole 404 page in Russian for missing pages under /ru/
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- javascript
- Domain
- internationalization
Research direction
Start with src/theme/NotFound/Content/index.js and i18n/ru/code.json to see how the 404 texts are already switched to Russian in the browser. Then find where the root 404.html is served for /ru/ paths and compare it with the built /ru/404.html. Done means a missing /ru/ URL shows a fully Russian page, with a Russian navbar, footer and links, and the choice between the two proposed approaches is recorded in the thread first.
Written by the indexing model from the issue text.
Description
Problem
GitHub Pages serves only the root 404.html for every missing path, and ignores 404.html files in subfolders. The root 404.html belongs to the default (English) build, so a broken link under /ru/, for example https://docs.lsfusion.org/ru/404/ or https://docs.lsfusion.org/ru/development_manual/, opens the English 404 page. The Russian page that Docusaurus builds at https://docs.lsfusion.org/ru/404.html is never used for such links.
The texts of the 404 page are now switched to Russian on these paths: src/theme/NotFound/Content/index.js takes them from i18n/ru/code.json in the browser. The rest of the page still comes from the English build:
- the navbar and the footer are in English;
- their links lead to the English pages, for example
Learnleads to/instead of/ru/.
Possible solutions
- On a path under
/ru/, redirect the root 404 page to/ru/404.html. The page becomes fully Russian, but the address bar shows/ru/404.htmlinstead of the broken URL. - On a path under
/ru/, load/ru/404.htmland replace the current document with it, keeping the URL. The page becomes fully Russian and the broken URL stays visible, but this relies on non-standard behaviour of a Docusaurus page and needs to be checked again after Docusaurus upgrades.
- Dominant language
- JavaScript
- Stars
- 2
- Forks
- 4
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from lsfusion/docusaurus
-
Difficulty 1/5 Under an hour Newbie friendliness 45/100
lsfusion/docusaurus#13 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
lsfusion/docusaurus#12 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
lsfusion/docusaurus#2 ·
All issues in lsfusion/docusaurus
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
[Windows] Hidden title bar: a maximized window restored from minimized on a secondary monitor gets the primary monitor's work area as its client areaPossibly taken @lijy91 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
libnativeapi/nativeapi#53 · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
KilledByAPixel/LittleJS#188 ·
-
[workshop-sync] workshop/06-install-gh-aw.md: outdated version example and gh aw init file listOpendocumentation
Difficulty 1/5 Under an hour Newbie friendliness 86/100
githubnext/gh-aw-workshop#6053 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
JuliusBrussee/caveman#1567 ·
Maintainers usually reply within 1 day