Share Note plugin 🚀 - share individual notes with full support for themes, images, Dataview, callouts, and more

Neither actually. If you have a version prior to 0.2.0, please refresh and you’ll see a better experience. The API key is there as a way to check that the user is a person and not a bot. It’s solely there as a way to prevent abuse (e.g. some bot spamming the server and filling up all the storage).

Encryption is done locally inside your Obsidian, and is already encrypted before anything is sent to the server. Each note is encrypted with its own random salt - your own notes are completely unrelated to each other, and also from any other public note.

3 Likes

@gapmiss I have updated the docs to show the API calls and a reference implementation:

https://github.com/alangrainger/obsidian-share/blob/main/docs/Running%20your%20own%20server.md

2 Likes

Version 0.3.0 released

https://github.com/alangrainger/obsidian-share

New features

  • Add a Copy shared link item to the 3-dot menu. This is especially useful on mobile.

Screenshot_20230920_134441_Obsidian

  • Can set uploads to be light/dark theme, regardless of your Obsidian display mode

  • Add the ability to share an individual note unencrypted. This allows you to have a preview of the note visible when someone pastes a link.

Here’s an example of an unencrypted note showing the preview text:

Improvements

  • Fixed issue sharing very long notes (10,000 words+)
  • Fixed issue with some fonts not uploading correctly
  • Responsively add/remove mobile classes when viewing the note
3 Likes

Thanks again for your plugin. I’m in the process of creating a site with my notes thanks to your plugin, whereas I’ve been struggling until now with various publish plugins.
But I would have liked to be able to extend the line length of my shared notes. I noticed that it was mentioned in the code as if it were an available parameter, but it’s not available in the plugin parameters. Will this be implemented in future versions ?

Sorry - that should have been on the Settings page.

It’s there now in v0.3.1 if you update the plugin. Please note that the width will still be limited by the width that is set in your Obsidian theme.

1 Like

Thank you very much. The parameter was added and I was able to expand my pages.

1 Like

Hey!:wave:

Writing here with a feature request.

Would be cool to have Telegram’s “InstantView” compatibility like it’s made in Telegra.ph

Thanks!

Can you explain what that is? I’m not familiar.

Is it possible to put external links via html that open in the same tab? I’ve tried using the classic target=“_self” syntax, but the links keep opening in a new page:

<a href="https://file.obsidianshare.com/82/ed9e619fba04b9d8f2b582ae66f58a34.html#53l2EQj/WTjGL6vr/BcnHtR4mJ23amwFD8qpoCNsoiY"  target="_self" style="text-decoration: none; color: #333; font-weight: bold;">
		<div style="border: 1px solid gray; padding: 10px; text-align: center; border-radius:10px; background-color: #5c5c5c; height: 100px; display: flex; flex-direction: column; justify-content: center; color: white;">
			📑 Cours Excel
		</div>
	</a>

I will remove the target=blank. It’s what Obsidian does but it’s bad UX for a webpage. Didn’t realise it was there.

https://github.com/alangrainger/obsidian-share/commit/f2c77fb60eb0e6a1545632f3d2366861553a545f

Will go live in next version.

Thank you very much.

@Anwen it’s live in 0.3.11

I’ve updated the plugin version and reforced the note sharing, but the external links still open in a new tab. When I look with the browser inspector, there always seems to be the target=“_blank” in the external links of the shared note :thinking:.
On the other hand, there’s no such problem when you put external links in markdown, it only appears when you put external links in html.

Ok, I can see what you mean in the other post - you’re using your own HTML inside your note.

The Share Note plugin is faithfully replicating exactly what Obsidian is outputting (check your preview mode - you’ll see there is a target=_blank for those links).

To get around this, add either the external-link or internal-link class to the <a> tag, and then your link will be in a format that Obsidian recognises, and the target will be stripped on upload.

<a class="internal-link" href="https://...
1 Like

Thanks, I’ve added the external-link class, and it does work. Thanks again for the great plugin.

1 Like

Yeah, sure! It would be better if I just share their article on that. There is everything you need: https://instantview.telegram.org/

Thanks for the info :+1:

If you share a note unencrypted, it will publish the meta description and Open Graph tags.

I’m not sure if that will help with Telegram, but I don’t plan to add anything extra to support Telegram InstantView. If the Open Graph tags aren’t enough and you have to coding ability, please feel free to submit a Pull Request.

Just be aware that this could only ever work for unencrypted notes, as otherwise that preview data will (and should) be encrypted.

1 Like

I’m sorry to bother you again, but is there a note size limit for sharing? I can still share notes, but there was a note I had shared, I added content with a lot of codeblock, and now I can’t share it anymore. The pop-up at the start of the sharing process appears, but then nothing happens and the link isn’t updated.
I don’t know if it concerns the plugin, but the only error messages in the console are these:
[Violation] ‘requestAnimationFrame’ handler took 89ms
[Violation] Forced reflow while executing JavaScript took 81ms
plugin:share-note:539 [Violation] ‘setTimeout’ handler took 64ms
[Violation] Forced reflow while executing JavaScript took 56ms

@Anwen can you please update to 0.3.14 and test again.

If the error persists, please open an issue with the details here:

https://github.com/alangrainger/obsidian-share/issues

Ok, sorry. This wasn’t actually due to the size of the note, but to the fact that I was using a plugin to style my codeblocks, in particular to give them a title. Nevertheless, I opened an issue on github.