Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

How to create wiki links to H1/H2 headers in a document#812

Unanswered
rbhanot4739 asked this question inQ&A
Discussion options

Hello,

I am not sure if this is supported or not but in the Obsidian app when I type[[ followed by## it lets me create wiki link directly to a header tag(h1/h2/h3...) inside of that document. However, with this plugin when I type[[ the autocompletion popup only shows the document titles/Ids and so I can only create a link to the doc only.

I can manually edit the link and put a# and create the link but it would be nice if cmp source can also show the header tags for a document which makes it easier to create a wiki link directly to that tag. This is my config for reference

{"epwalsh/obsidian.nvim",version="*",-- recommended, use latest release instead of latest commitlazy=true,dependencies= {"nvim-lua/plenary.nvim",    },opts= {ui= {enable=false,      },workspaces= {        {name="personal",path=vim.fn.expand("~").."/Google Drive/My Drive/Obsedian",        },      },notes_subdir="Main",note_id_func=function(title)localsuffix=""iftitle~=nilthensuffix=title:gsub("","-"):gsub("[^A-Za-z0-9-]",""):lower()elsefor_=1,4dosuffix=suffix..string.char(math.random(65,90))endendreturntostring(os.time()).."-"..suffixend,    },
You must be logged in to vote

Replies: 0 comments

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Category
Q&A
Labels
None yet
1 participant
@rbhanot4739

[8]ページ先頭

©2009-2025 Movatter.jp