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

Add link to source files #1899

Open
bsmth opened this issue Jul 17, 2024 · 0 comments
Open

Add link to source files #1899

bsmth opened this issue Jul 17, 2024 · 0 comments
Labels
enhancement Improves an existing feature.

Comments

@bsmth
Copy link
Member

bsmth commented Jul 17, 2024

It happens frequently when you want to update an example that you have to search through the interactive examples repository to find the correct source files. Given we're templating the output, it would be convenient to add links to sources somewhere, even if this is hidden / not reader visible.

Some options for CSS could be:

<span><a href="https://github.com/mdn/interactive-examples/blob/main/%example-css-src%">CSS Source></a></span>

<a href="https://github.com/mdn/interactive-examples/blob/main/%example-css-src%" style="display: none;">CSS Source></a>

Or some variations on that. Linking to the directory if it contains multiple files (CSS/JS) would already be helpful.

edit: If this was combined with Yari improvements, we could display hints to authors only when on localhost, for instance, via CSS class or something.

@bsmth bsmth added the enhancement Improves an existing feature. label Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improves an existing feature.
Projects
None yet
Development

No branches or pull requests

1 participant