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

Documentation should have a copy button for code snippets #1080

Closed
SoulPancake opened this issue May 6, 2023 · 1 comment · Fixed by #1083
Closed

Documentation should have a copy button for code snippets #1080

SoulPancake opened this issue May 6, 2023 · 1 comment · Fixed by #1083

Comments

@SoulPancake
Copy link

SoulPancake commented May 6, 2023

No description provided.

@abhinav
Copy link
Collaborator

abhinav commented May 6, 2023

Fx friends, FYI, this can likely be accomplished with https://www.npmjs.com/package/vuepress-plugin-code-copy. That's what Cadence uses to get this in their documentation.

sywhang added a commit to sywhang/fx that referenced this issue May 8, 2023
This adds the "copy" button for all code snippets in the docs example
so that users can easily copy the example code to their clipboard.

Fix uber-go#1080.
sywhang added a commit that referenced this issue May 8, 2023
This adds the "copy" button for all code snippets in the docs example so
that users can easily copy the example code to their clipboard.

Fix #1080.

Example after change:

<img width="730" alt="Screen Shot 2023-05-07 at 10 37 26 PM"
src="https://user-images.githubusercontent.com/30421794/236742738-79285d4c-c723-41cc-8e22-0a6a06d461a1.png">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants