Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I put a hyperlink inside a list in Markdown on GitHub Pages?

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.

like image 811
Ivan Avatar asked Sep 21 '18 03:09

Ivan


People also ask

How do I add a link in Github Markdown?

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).

How do you reference a link in Markdown?

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.

How do you underline in Github Markdown?

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.


2 Answers

It should be:

  1. [Caption](https://example.com)
  2. Another list item
like image 122
Alex Harvey Avatar answered Sep 23 '22 08:09

Alex Harvey


From GitHub's "Mastering Markdown":

Links

http://github.com - automatic!
[GitHub](http://github.com)

Mastering Markdown]

https://guides.github.com/features/mastering-markdown/#Links

like image 36
C. Augusto Proiete Avatar answered Sep 23 '22 08:09

C. Augusto Proiete