Copy button on inline code and block code

Is there a functionality where you can copy code from inside a block code or inline code? I currently use Boostnote which does have that feature, but their newer version did away with that.
copy_inline_code

3 Likes

Nope, Joplin does not have this feature.

Hi,

Any chance that this feature could be implemented?
It would make life easier when copy-pasting big codeblocks.

An icon to copy or just an option in the right click context menu would suffice.

Thanks!

1 Like

@aorith

1 Like

@bedwardly-down

Thanks mate, I totally missed that.

1 Like

You’re fine. It just popped up out of nowhere very recently and most people missed it. Ha

And you are not the only one requesting this!

1 Like

It's great that we now have a plugin for code blocks, but we still need one for inline code.

There is Joplin Plugins - Click to copy but it requires a non stand delimiter ([[…]]) and does not work for standard inline code (backquotes).

What we need is a solution so that a single click on any inline code (single backquotes) copies its content to clipboard.

Big news, there is now a one click copy solution for inline code as well!

It was implemented in the very recent 1.3.3 version of https://joplinapp.org/plugins/plugin/com.joplin.click.to.copy/

Simply set delimiters as backquotes instead of default [[ and ]]. They now work correctly.

Kudos to @ntczkjfg

Relevant links:

3 Likes

nice, being able to use backticks for this is handy!

As an update to this: I just pushed version 1.4.0. You can still set the start and end tokens to backticks if you prefer - but now, in settings, there are options to directly make inline code spans click-to-copy without having to change your tokens.

For anyone who wants all inline code spans to be click-to-copy, I recommend this over changing the tokens - it preserves the functionality of the plugin for other applications and is also a little cleaner visually with the CSS.

2 Likes