Homepage    |    GitHub    |    API    |    FAQ

Safari App Extension for Joplin now available

I’ve really enjoyed using Joplin, and it has worked well for me on a Mac. I’ve always wanted to be able to clip pages from Safari, however. I finally started to develop a Safari App Extension a while back and managed to get something working.

It does the basics: Clipping pages (complete and simplified); clipping URLs and selections; tagging; selecting folders; changing the title; checking on server status and disabling the controls if Joplin isn’t running. It’s based on the Web Clipper for Chrome and Firefox provided with Joplin, with Javascript modifications to support Safari App Extensions and, of course, a native-based UI. Some things are not implemented (complete HTML clipping and screenshot capture), but the basics are there.

One item to note: It does operate differently than the Chrome/Firefox Extension, in that the “Clip” buttons operate immediately. There is no “Confirm” step after selecting your Clip option.

Overall, while definitely beta-level code, it is stable enough for daily use. It’s been great to be able to use Safari to clip content into Joplin and not have to jump over to Chrome.

Unfortunately, my timing could not have been worse, thanks to the recent WWDC2020 announcement of Web Extensions coming to Safari. I wanted to put a little more polish on this and clean up the code some more (it’s my first real App Extension). I suspect that eventually this will be replaced by the Chrome/Firefox Clipper updated for Safari, so I figured I’d release it now and hope people get some use from it.

Initial release is here: https://github.com/cweirup/JoplinSafariWebClipper/releases/download/v0.1.2/Joplin.Clipper.zip

Github Repo here: https://github.com/cweirup/JoplinSafariWebClipper

Thanks!
Chris

8 Likes

Hi, First of all thanks for taking the time to create this app. I’m with you on needing this for Safari.

Unfortunately I’ve downloaded and installed the web clipper app for Safari and can’t seem to get it to work. I’ve enable it in the Safari preferences, see the icon next to the address bar, however when trying to clip a page it just gives you the message that it’s in progress, and never seems to get the job done. No note appears in Joplin anywhere that I can find. I’ve tried simplified and complete clipping options with the same results.

Safari version: 13.1.1 (15609.2.9.1.2)
MacOS Catalina: 10.15.5
MacBook Pro 13 inch (2019, Four Thunderbolt 3 ports)

I am not an Apple user but I can imagine that this problem occurs when the clipper service isn’t enabled in the joplin options. Did you enabled the service (in Joplin Desktop go to: Tools–>Options–>Web clipper and click on “Enable Web Clipper Service”)?

The web clipper service is running. I’ve been using it via Firefox extensions for some time without issue.

The extension on Safari also shows the green light that it sees the web clipper service is running

Are you seeing this on every page you visit or pages you already have loaded in Safari? One thing to try is to reload the page and try it again.

For some reason, if you try to run the Extension right after it is installed on a page that was previously loaded, it hangs at “Processing”. If you refresh/reload, it should work as designed. I believe it has to do with the content script not being fully injected but I need to investigate further.

Thanks Chris,

You seem to have solved the issue here. I couldn’t recall if I’d reloaded the pages I tried it with since installing the app. I tend to keep a lot of tabs open in Safari. Trying it on a new tab loaded up after installing the Webclipper plugin seems to work perfectly.

Thanks again for all your hard work on this.

1 Like

The extension is awesome!

I don’t think the timing is bad at all. Yes, Web Extensions API will be in macOS Big Sur … but that releases this Fall & will take a year to really permeate. Your extension will be useful & valid for much longer considering those that lag on OS updates (as potentially bad as that might be).

This fills a gap perfectly.

Thanks! I appreciate the words of encouragement.

This is awesome and might be what lets me switch to Joplin.
I might be missing if you said this, but how do I install this once I’ve cloned the repo?

You don’t need to clone the repo to install it. There’s a compiled version of it under Releases.

You can get the latest here: https://github.com/cweirup/JoplinSafariWebClipper/releases/download/v.0.1.3/Joplin.Clipper.zip

Just unzip, move the executable to the Applications folder, and run the app once. You’ll be prompted to enable it in Safari Extensions, then you should be good to go.

Ah, ok. I wasn’t seeing the releases link. Thanks!

Just a heads up, this web clipper app seems to still work following an upgrade to Safari 14 (which is supposed to enable chrome extensions).

Hi everyone! Just wanted to let you all know that I updated the Safari App Extension to support the new APIs introduced in Joplin v1.4.12.

If you are running that version or later of Joplin, you will need to upgrade to this latest version of the Extension (v0.2.0); otherwise, you will no longer be able to select folders or save pages.

Latest Version of Extension: https://github.com/cweirup/JoplinSafariWebClipper/releases/download/v0.2.0/Joplin.Clipper.zip

Thanks!
Chris

4 Likes

Thank you very much, your extension works perfectly !

Hey this looks great, thanks for you effort.
Do you have plans on merging this to the original Joplin repository? Can I help in any way?

Where can I get the updated version of the web clipper for safari 14 compatible with the desktop application 2.1.9 ? Thanks.

@cweirup, if that can help I've documented there how to get the token from the API: joplin/clipper_auth.md at dev · laurent22/joplin · GitHub

@leclercfl Still working on it. I have something working but it's pretty rough. I've been pulled into a work project that's limited my free time, but I'm hoping to have an update published in the next week or so. I'll post something here when it's ready.

@laurent Thanks for sharing that info! That's been a big help!

Thanks!
Chris

1 Like

@leclercfl I have a new build that should support the authorization mechanism in Joplin now. Check it out with Joplin v2.1.5 or later. You will most likely encounter bugs if you refuse an auth request, but for the most common cases the Clipper should be functional.

Thanks again, @laurent!

3 Likes