ArianaKhit / text-snippets-obsidian

Snippets plugin for obsidian
187 stars 23 forks source link

Can't create right arrow snippet #18

Closed rasmusrhl closed 2 years ago

rasmusrhl commented 2 years ago

I'm trying to create a right-arrow snippet, using -> as the snippet-text, and trying to get this arrow symbol: →.

But when I try to create the snippet in 'Text snippets - settings', by typing or inserting ->, it is changed to the symbol (→).

Giving me this: image

Which is not a usable snippet (becuase it does not transform -> into →).

Arax20 commented 2 years ago

Have you tried actually using that snippet? Obsidian handles settings differently than the editor and one of the differences is that font ligatures are used in the settings pane.

Roughly speaking, some character pairs are combined visually into symbols but this is only visual and doesn't affect the real text content, so even if it looks like a symbol the code should still treat it as -> and not .

I tried it out and that's how it worked for me at least.

rasmusrhl commented 2 years ago

@Arax20 You are absolutely right! It works just as you said, when I actually try the snippet in the editor.