Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The "Create issue" feature should auto-include doc URL #91

Open
Tracked by #1841
sarahmaddox opened this issue Jun 16, 2019 · 1 comment
Open
Tracked by #1841

The "Create issue" feature should auto-include doc URL #91

sarahmaddox opened this issue Jun 16, 2019 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@sarahmaddox
Copy link
Contributor

sarahmaddox commented Jun 16, 2019

When a user clicks Create issue on a doc page, Docsy should auto-include the relevant doc URL (or at least the path) in the created issue. Currently, Docsy includes the page title as the title of the issue, but nothing in the page body.

The Feedback widget should also include the URL of the page when a user creates an issue based on their feedback.

I got part of the way there by editing the file /docsy/layouts/partials/page-meta-links.html and adding the the issue body URL param with a value of .Permalink (or .Path) in this line:

{{ $issuesURL := printf "%s/issues/new?title=%s&body=%s" $gh_repo (htmlEscape $.Title) .Permalink }}

However, there's probably further testing required. For example, should we use .Path or .Permalink. Not all sites have their base URL set to include the domain. For example, in the Kubeflow site, our base URL is set to just a /. This affects the value of the .Path.

@RichieEscarez
Copy link
Contributor

In Knative we add the path to the Create Issue link and also accommodate several different conditions due to the doc set versioning we have. You might be able to use some of our overrides to inspire a Kubeflow specific fix: https://github.com/knative/website/blob/master/layouts/partials/page-meta-links.html

@emckean emckean added the enhancement New feature or request label Jun 2, 2023
@emckean emckean self-assigned this Jun 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants