facebook / facebook/docusaurus
Find a way to link to category generated-index
- Lingua principale
- TypeScript
- Stelle
- 66.2k
- Fork
- 10k
- Merge medio
- 1g 3h
- PR unite (30g)
- 52
Descrizione
### Have you read the Contributing Guidelines on issues?
- [X] I have read the [Contributing Guidelines on issues](https://github.com/facebook/docusaurus/blob/main/CONTRIBUTING.md#reporting-new-issues).
### Motivation
For docs, we recommend using relative file paths:
For our new category index feature, there is no `.md` file to link to so we must use regular links.
Problem:
- Using an absolute link would not play well with versioning: `[Guides](/docs/next/category/guides).`
- Using a relative link would not play well with changing the `trailingSlash` setting: `[Guides](./category/guides).`
This is particularly annoying for our own website, as we use different settings for dogfooding on dev/deployPreview/prod. It is not easy to find a good workaround so that our site could be deployed on every env without reporting broken links 😅 (see workaround https://github.com/facebook/docusaurus/pull/5830/commits/ac44531f61eb53818cf1dd6e30a585a8526ea288)
It may be annoying for our users too.
We should probably find a way to link more easily to a category, but not sure how this should be done 🤷♂️
### Self-service
- [ ] I'd be willing to do some initial work on this proposal myself.
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.