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 a "copy" button to code blocks #370

Closed
chipzoller opened this issue Nov 13, 2020 · 1 comment
Closed

Add a "copy" button to code blocks #370

chipzoller opened this issue Nov 13, 2020 · 1 comment

Comments

@chipzoller
Copy link

This (cool, btw) theme is commonly used for documentation of "technical" subject matters which often include code. It would be super helpful if there were just a simple "copy" button somewhere in that code block providing users an easier way to select all and copy what's in that block. We implemented that plus other functions in our Clarity theme, so if no one can pick this up it might be something we could look at doing in the future.

@LisaFC
Copy link
Collaborator

LisaFC commented Nov 19, 2020

If you switch to using Prism for your code highlighting, you'll get a copy button!
https://www.docsy.dev/docs/adding-content/lookandfeel/#code-highlighting-with-prism

(we didn't make Prism the default just because a lot of our users rely on Chroma styles, but it's easy to switch)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants