This joplin plugin allows to remove all images in selected note. To use this you can just press on Remove Images button in Editor Toolbar or go to Tools -> Remove Images. Note: Currently, This plugin is intended to work only on Markdown Editor.
Installation
Remove Images can be installed from within Joplin by navigating to the plugins page in the settings menu then searching for and installing "Remove Images"
It might be worth adding an option to specify only removal of Joplin resource images i.e. extend the regex to only look at tags containing (:/ at the start of the link section in order to not break any notes that use links to pictures elsewhere on the filesystem or online.
My reasoning is that the links with external references tend to be deliberate and obviously don't take up disk space which would be my main reason for wanting to purge images in the first place.
Another suggestion would be to only target image links within a highlighted section rather than over the entire document (or the reverse, purge everything except the highlight) - for example if you web clip you might want the "proper" images but you want to purge the extra website logos or links to other pictures you don't want.
I agree with this. I can add an option to only remove Joplin resource images. My reasoning for implementing it this way was if a user web clip a page and don't want any images then user can use this plugin.
I had similar idea in my mind. I will try to implement it soon.
There is also a small issue with the way this handles hyperlinked images as taken by the webclipper.
For example clip: Human head - Wikipedia
Some image links are shown within hyperlinks e.g. [![Proportions of the Head.jpg](:/b8ce842087404b30a91c4892cc97e805)](https://en.wikipedia.org/wiki/File:Proportions_of_the_Head.jpg)
Running your plugin results in a weird empty link that isn't rendered (as it has no text) i.e. [](https://en.wikipedia.org/wiki/File:Proportions_of_the_Head.jpg) as it is only reading the image tag part.
So I guess it should either be taking the entire string out or it should be replacing the now empty [] section with the contents of the resource section.
Happy to open it as an issue on your repo if you want.
Thanks for the plugin! This is something I will surely use.
I can confirm Daeraxa's experience that something like this: [<img width="210" height="24" src=":/51ae88f25d8f41808bcdc7a0496c8b2a"/>](https://www.freecodecamp.org/news)
became [](https://www.freecodecamp.org/news)
In my opinion, if I am wanting the image removed, I'm wanting the whole thing removed. The fact that the image was an anchor to something else doesn't matter.
I also like the idea of removing images in text that is not selected. In any case, I do think it's good to offer some selection option for the reason Daxera said.
Hey guys,
As suggested above I have updated the plugin to remove all kinds of images and patch for this is published so now you should be able to update the plugin.
(Plugin can remove images of all the following types now: )
I noticed that it leaves behind a blank line where the image code used to be. I wonder if it should also be removing that? Rendered it doesn't matter. But it might be cleaner to have them removed.