Fix homepage feature links (404s and wrong URL)#218
Open
alienx5499 wants to merge 1 commit intodrand:masterfrom
Open
Fix homepage feature links (404s and wrong URL)#218alienx5499 wants to merge 1 commit intodrand:masterfrom
alienx5499 wants to merge 1 commit intodrand:masterfrom
Conversation
Author
|
@AnomalRoil @CluEleSsUK This PR fixes two production issues on drand.love:
Marking for visibility since this affects live users. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes broken behavior for the homepage feature buttons (API docs, Go, JS):
404 on API docs — The "API docs" link pointed to
/developer/http-api, which does not exist on drand.love; developer docs live on docs.drand.love. The correct URL ishttps://docs.drand.love/dev-guide/developer/http-api.Wrong URL when clicking — Using
<router-link :to="...">with fullhttps://URLs made Vue Router treat them as paths, so clicks opened e.g.http://localhost:8082/https:/docs.drand.love/...instead of the real docs URL. External links now use a plain<a>so they open correctly.What's wrong on live (https://drand.love/)
https://drand.love/developer/http-api. That path doesn't host the real API docs (they're on docs.drand.love), so users get the wrong page or a 404.drand.love/https:/docs.drand.love/developer/clients/#go-(and same for JS). The site origin is prepended to the full URL, so the link is invalid and breaks in production as well as on localhost.Screenshots
Before (live site)
Changes
docs/README.mdlink: /developer/http-api→link: https://docs.drand.love/dev-guide/developer/http-api.../developer/clients/#go-and#javascript--typescript-).docs/.vuepress/theme/components/Home.vuehttp://orhttps://now render as<a href="..." target="_blank" rel="noopener noreferrer">instead of<router-link :to="...">, so external URLs open in a new tab and no longer get the current origin prepended (fixes the malformed URL in both dev and production).http://orhttps://(e.g./about/,/loe/) still use<router-link>and behave as before. Only the three feature buttons are affected; the rest of the page (Learn more, Get involved, footer, nav, etc.) is unchanged and still uses VuePress's default link handling.Checklist