Skip to content

UpdateLinksInFileParams.linkStyleProvider?

UpdateLinksInFileParams › linkStyleProvider?

Type: (link: Reference) => LinkStyle | undefined

Decides the style of one link, overriding linkStyle for it. Returning undefined keeps linkStyle.

Use it when one style for the whole file is wrong for some of its links. A caller forcing LinkStyle.Markdown over a note, for example, keeps a frontmatter wikilink a wikilink, because Obsidian reads a property value as a link only in that form.