Closed ZhangYiJiang closed 6 years ago
Thanks for the report and detailed explanation @ZhangYiJiang. We should probably apply a fix somewhere in here: https://github.com/marko-js/markojs-website/blob/master/routes/docs/util/markdown.js#L79
This was actually an issue with the relative URLs in the Markdown files. I've fixed this and published a new version. We still need to publish a new version of the website.
Details
The links to framework integration (Express, Koa, etc.) on https://markojs.com/docs/server-side-rendering/ in the section that starts with "ProTip: Marko also provides server-side framework integrations" go to 404 pages (eg. https://markojs.com/docs/express.md, the correct URL is https://markojs.com/docs/express)
Expected Behavior
The links should go to the correct page
Actual Behavior
The links go to 404 pages
Possible Fix
The bug is caused by the
.md
extension on the links. Removing them will probably fix the issue, but then the links on the source Markdown file viewed on GitHub at https://github.com/marko-js/marko/blob/master/docs/server-side-rendering.md would break.Ideally the extensions should be stripped when the documentation site is built, or URL rewrite can be done on the server to remove the
.md