dendron
dendron copied to clipboard
Allow Use of non-pretty Refs and pretty Refs in the same note
Please select if your request is either something new or an enhancement
- [X] Enhancement of an existing Feature.
- [ ] Request of a new feature.
Please select the area your request applies to. (Multiple selections are Possible. You can leave blank if you're not sure.)
- [ ] Workspace - VSCode workspace, vaults, Intellisense/autocomplete, Dendron settings
- [ ] Lookup - Dendron's Lookup Command
- [X] Views - Dendron Preview, Tree View, Side Panels in the UI
- [ ] Schema - Dendron Schemas
- [ ] Pod - Data import from / export to Dendron
- [X] Publish - External Site Publish
- [X] Markdown - Markdown features, such as syntax support and features
A clear and concise description of what the problem is.
Pretty Refs are really nice, one of the main reasons I like dendron. However, sometimes I feel like I want to use both pretty refs and non-pretty refs in the same note.
Describe the solution you'd like
The current syntax for refs is ![[...]]
. I would the possibility to add a !
at the beginning to use the non-default for the note.
So these are the two cases:
- Note has pretty ref enabled:
-
![[...]]
creates a pretty Ref -
!![[...]]
creates a non-pretty Ref
-
- Note has pretty ref disabled:
-
![[...]]
creates a non-pretty Ref -
!![[...]]
creates a pretty Ref
-
Additional context
For example, I wanted to compile a table from the contents of different notes, and with the use of pretty refs inside the table it can get pretty big, and it would be better to use non-pretty Refs in this case:
However, I want to also use pretty refs in the rest of the note.
This also could work similar to #2038, which describes adding properties to links. We could do something like ![[note]]{ usePrettyRef: false }
to override the setting per link.
ooh, that's also a good idea and would be more versatile!
Whoa, I didn't know non-pretty refs existed! Wanted to ask for something like this for a long time, ha-ha 🙂 And yeah, having an option to set ref type per link would be great.
Sort of not very related, but do you know if it's technically in VSCode possible to render refs in the editor and be able to edit them in place, without having to switch to the ref file?
if it's technically in VSCode possible to render refs in the editor and be able to edit them in place
We could display them relatively easily, but editing would be very hard. You could code up something were you insert the text temporarily then copy the changes back or something, but it might be very unstable. Display is easier because VSCode allows decorations to overlay text over the current document.
This issue is featured in this week's round of CROP voting on Dendron's Discord server.
The community has selected this issue as this week's CROP winner. 🎉