Backlink from image

Steps to reproduce

Consider the following Markdown:


$$
\alpha 
$$      -


![[gnu.png]]

where the gnu.png file is this file : heckert_gnu.transp.small.

When I open the png, there is no backlink:

But if the markdown is changed to (notice that the minus sign is on a separate line):


$$
\alpha 
$$
-


![[gnu.png]]

then the backlink appears:

Did you follow the troubleshooting guide? [Y/N]

Y. There is no plugin involved. The test was done using the sandbox vault.

Expected result

When opening the png figure, there should be a backlink to the original markdown file.

Actual result

There is no backlink.

Environment

SYSTEM INFO:
Obsidian version: v1.8.10
Installer version: v1.6.3
Operating system: Windows 10 Enterprise 10.0.22631
Login status: not logged in
Language: fr
Insider build toggle: off
Live preview: on
Base theme: adapt to system
Community theme: none
Snippets enabled: 0
Restricted mode: on

RECOMMENDATIONS:
none

A remark, if you use this syntax in source mode:

  
$$
\alpha 
$$      -

![[gnu.png]]

The latex formula is not correctly detected, as it can be seen if you switch to preview mode, which renders:

image

This is the reason why the outgoing link is not “seen” by obsidian.

Apparently, if you want to use $$ as delimiters in a line alone, you cannot include more text in that line (like the dash). That confuses the parser and assumes that those $$ are not math delimiters.

You can instead use $$ in the same line than the formula it delimits. In this case you can have more text in the same line, eg:

$$ \alpha $$      -

![[gnu.png]]

and this works:

And the backlink is detected correctly.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.