Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve markdown template #346

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nicholaschiasson
Copy link

@nicholaschiasson nicholaschiasson commented Mar 8, 2021

Heavily based on ldoc_ltp.lua.

Requires template_escape = "!" setting in config.ld.

Heavily based on .
@Tieske
Copy link
Member

Tieske commented Mar 9, 2021

Requires template_escape = "!" setting in config.ld.

Isn't that a breaking change? Can't we stick to the original ( > iirc)

@nicholaschiasson
Copy link
Author

@Tieske Yes I think I didn't do enough investigation for this change. I will make it a draft and come back to it.

However, my decision to change the template escape to something else was because > is the block quote character in markdown spec. I don't know the best way to address this.

@nicholaschiasson nicholaschiasson marked this pull request as draft March 9, 2021 15:09
@berwynhoyt
Copy link

Tieske, I found your .md template to be very helpful in drafting my own markdown template. Yes, the built-in one is too simplistic.

But regarding your question on the escape character, I suspect that > was chosen specifically because it is a block quote character in markdown: you wouldn't normally want a block-quote hard-coded into a template. And if you did, you could easily start your template line with $('>') to achieve the same effect.

However, I did find that yours needs some polishing. For example, whitespace is not trimmed from the ends of item names, and I found that my markdown renderer (Typora) requires - within hrefs, rather than _.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants