You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suggest adding an option to copy the code snippets to your clipboard. Clipboard.js is a nice JavaScript library which makes it super easy.
If you agree, I will start working on this :)
The text was updated successfully, but these errors were encountered:
@marcobiedermann apologies for not getting back to you on this sooner man. I haven't had much free time lately and have been neglecting my open source projects a bit. This sounds like a good idea to me 👍 My attempt to make it convenient to select/copy snippets by auto-selecting all text in a code block was a poor choice.
I don't think the "Copy to Clipboard" functionality is possible with the current layout of the static site, which is made on Jekyll. All the content on http://gethead.info is parsed from the README.md file. It is simply not possible to add the copy functionality in a markdown file.
One possible solution would be to divide every code block into individual files and place them in the _includes folder. It would then be possible to add a "Copy to Clipboard" button at the end of each code block insertion in the index.html file. This too, sounds too complicated to be implemented.
@dakshshah96 copy to clipboard functionality should be possible to layer on with some javascript. I'll see if I can add this in the near future unless anyone else wants to do it and submit a pull request 😉
I suggest adding an option to copy the code snippets to your clipboard.
Clipboard.js is a nice JavaScript library which makes it super easy.
If you agree, I will start working on this :)
The text was updated successfully, but these errors were encountered: