MAS1112 MAS1112 - 4 months ago 16
Jade Question

Parse URL and create Links On Plain-Text Jade

I am getting plain-text in which there could be a URL.

For Example
: learn abc in one day www.englishspeaking.com

Here I am having a URL. I want to convert it has a link. I am using Jade template engine. Is there a way to do this in Jade template engine.

Answer

Use markdown filter like this

:markdown
  this is the start of the para.
  [a link](http://example.com)
  and this is the rest of the paragraph.