I have tried the following syntax to make a Markdown list item on a GitHub page of mine a hyperlink:
1. [Caption]: https://example.com
2. Another list item
Contrary to intuitive expectations it renders into the following HTML code
<ol>
<li></li>
<li>Another list item</li>
</ol>
How can this possibly be fixed? Is there a correct syntax for this? My intention was to create a clickable list of sources of the information used to write the article and put it in the bottom part of it.
There are two ways to create links. Or leave it empty and use the link text itself. URLs and URLs in angle brackets will automatically get turned into links. http://www.example.com or http://www.example.com and sometimes example.com (but not on Github, for example).
Markdown supports two style of links: inline and reference. In both styles, the link text is delimited by [square brackets]. To create an inline link, use a set of regular parentheses immediately after the link text's closing square bracket.
Just use the HTML <u> tag (recommended) or the <ins> tag inside your markdown for this. The HTML tag <ins> is the HTML "insert tag", and is usually displayed as underlined.
It should be:
1. [Caption](https://example.com)
2. Another list item
From GitHub's "Mastering Markdown":
http://github.com - automatic!
[GitHub](http://github.com)
https://guides.github.com/features/mastering-markdown/#Links
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With