Full Wikilink Support [[Link Target|Description/Label]]
I would love if nvUltra would support the full Wikilink syntax [https://en.wikipedia.org/wiki/Help:Link#Wikilinks_(internal_links)]().
That way, when I render a note in Marked, I can properly embed Wikilinks into the flow of text without it looking like it usually would, and I can refer to the same note by different names, i.e. I could write:
Brett's [[Tagging - Brett Terpstra | tagging system]] is a lot more sophisticated than my own.
That would be _fantastic_ to have!
-
I would also like to be able to link to a section inside the same note, e.g. `[[#Section name|displayed text]]` or `[displayed text](#slug-of-section-name)`.
1 -
Some additional testing revealed that linking to headers with `[displayed text](#slug-of-section-name)` is possible, BUT the #slug-of-section-name differs from e.g. GitHub. Where GitHub would create an anchor "1-master-your-inbox" for a heading "# 1 Master Your Inbox", nvUltra's anchor is "1masteryourinbox". This means that copying and pasting between nvUltra and GitHub will break internal links inside a note.
0 -
Frank -- it's unfortunate that GitHub chose a different anchor hashing algorithm than the one used by MultiMarkdown, but they did. Not much I can do about that. And changing MultiMarkdown would break 10+ years of documents, so I am reluctant to do that without a *really* good reason.
As for the "full" WikiLink syntax, we'll see. Never say never and all that, but making WikiLinks more complex than they already are is not high on my list of priorities.
0 -
Dear Fletcher, I was not aware that this is also part of the MultiMarkdown standard. Abandoning MultiMarkdown's anchors in favor of GitHub's anchors would indeed not be very helpful to standardization. But since many of your users will be using both nvUltra and GitHub, would it be possible to add both anchors to a heading? The specification at https://www.w3.org/TR/selectors/#id-selectors suggests that you can: "If an element has multiple ID attributes, all of them must be treated as IDs for that element for the purposes of the ID selector." You could then have separate settings for "Add GitHub-flavored anchors to headings" and "Add MultiMarkdown-flavored anchors to headings".
Also, I could not yet find the anchor syntax in the help documentation and had to use Inspect Element in Marked to find out.
0 -
I don't think that is correct. I believe that is referring to having multiple *types* of id tags, not multiple instances of the same "id" tag. See this. Trying what you describe in an HTML validator shows `id="one" id="two"` as an error.
0
Please sign in to leave a comment.
Comments
5 comments