expectocode / pagong

pagong - a site generator for slow connections
Apache License 2.0
7 stars 2 forks source link

Autolinks require <> around them #2

Closed Lonami closed 3 years ago

Lonami commented 4 years ago

Autolinks are absolute URIs and email addresses inside < and >. They are parsed as links, with the URL or email address as the link label.

However, I am spoiled by the fact services like GitHub or Telegram among others don't require this (that is, a GFM text with https://example.com will render hyperlinked as https://example.com).

Is removing the need for < and > desirable? How would users place links as raw text without having it turned into a hyperlink?

expectocode commented 4 years ago

Hmm, it would be convenient, but it also feels as though this is the exact scenario which autolinks are designed to accommodate. I'm also wary of modifying the actual parsing code

Lonami commented 4 years ago

Yeah, it might be a matter of getting used to it. While I wouldn't be against modifying the parser, it's true it would be a lot more involved (we already had to copy over the code for HTML generation which is now duplicated between the dependency itself and our code). An alternative would be to scan the source markdown and insert <> on links we detect, which is ugly but I'm not fully against.

Lonami commented 3 years ago

I think I'm okay with links needing <> around them, as long as <example.com> links to the expected https://example.com and not to mysite.example.org/blog/example.com, so I'm closing this issue (if you disagree, please reopen explaining why).