Please can we have relative file paths working for img tag?
<img src="images/Blackbird%20drawing.jpg" style="width:40%;float:left"/>
<img src="images/Blackbird%20drawing.jpg" />
The second example when I use IAwriter or Typora or 1writer on my MD file is rendered correctly (the picture is on the left with the text wrapped round it). For Obsidian you just get a ‘square’ indicating a picture in the text. I sync my vault with my phone and 1 writer works with the images subdirectory.
A link like this would not work in obsidian, I know that there is the trick to add “file//: …” followed by the full path, but this is a huge problem for consistency. Say that I move my vault folder somewhere else or into a new pc… Now all of my notes containing images are broken.
Just support relative links inside html on obsidian. It’s been at least two years that I see people asking this on here and the go-to answer was “electron does not support this”. Well… Typora, MarkText and every other md editor based on electron actually support this.
The some-weird-looking-thing-which-is-obsidian’s-id Is quite non-trivial to obtain. One possible way is to use an app like a-shell to navigate to the vault folder, then you can inspect the path and see it. Also this weird looking thing changes with each Obsidian update.
same question. For the images embedded in html, it works with a absolute path like “c:\work\img\bird.png”, but fails with a relative path like “img\bird.png”. The relative path works for the standard markdown editor like typora or vscode. it’s confusing and hope fix this bug ASAP.
The Obsidian team’s reasoning is clearly weak. Not only does this somehow magically not affect any other Electron based markdown editor, but you can even make plugins that add the same functionality without much work too. And it’s not like the text files are much different from images within the workspace directory, there’s no secondary, backwards, system to access other files than markdown files. If you can access local text files, you can access local image files and whichever other type of file.
Truly, what a reasonable standpoint to say that it’s a security policy like it isn’t possible to either disable or work around without end-user friction. I suppose they should just limit access to text files too, because they’re also local files. Might as well switch over to pen and paper at that point too.
I honestly do not understand their reasoning to arbitrarily impose usability limitations like this. It’s not like they can’t limit file system access to the workspace folder and simply translate relative paths to it and not outside of it.