Is there a plugin or way to quickly create wikilinks / internal links, where I can select text, convert it to wikilink format, and immediately type in the linked page?

I prefer the wikilinks format since its cleaner and much easier / quicker to work with. What I’d like to do is select text and trigger a command (with a hotkey), so it looks like this: [[|text]], and the cursor (caret) is between [[ and | and I can type in the page I want to create a link for.

You could use the wrap with shortcuts plugin I linked yesterday with two taps of the left arrow key to move the cursor before the |.

Templater would also work and place the cursor where you want:

<%*
tR = `[[${tp.file.cursor(1)}|${tp.file.selection()}]]`;
-%>

Thanks, those are good solutions! I ended up going with this templater template:

[[<%tp.file.cursor() %>|<% tp.file.selection() %>]]

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