Skip to content

Instantly share code, notes, and snippets.

@curiouslychase
Last active September 28, 2021 09:43
Show Gist options
  • Save curiouslychase/8147693 to your computer and use it in GitHub Desktop.
Save curiouslychase/8147693 to your computer and use it in GitHub Desktop.
A code example of how to nest an image in an anchor link with Markdown.
<!-- The link we want our bower bird to point to -->
[1]: http://www.bower.io
<!-- The image url we want to use for our img tag source -->
[2]: http://bower.io/img/bower-logo.png
<!--
This will compile to two html nodes:
Anchor: [linked item][1]: <a href="1">linked item</a>
Image: ![alt text][2]: <img src="2" alt="alt text" />
The image node will be nested inside of the anchor node.
-->
[![Bower.io: A Frontend Package Manager. logo][2]][1]
<!-- Reference -->
[2]: http://bower.io/img/bower-logo.png
![Bower.io: A Frontend Package Manager. logo][2]
<!-- Inline -->
![Bower.io: A Frontend Package Manager. logo](http://bower.io/img/bower-logo.png)
<!-- Reference -->
[1]: http://www.bower.io
[My Bower Link][1]
<!-- Inline -->
[My Bower Link](http://www.bower.io)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment