Skip to content

Latest commit

 

History

History
58 lines (35 loc) · 2.54 KB

Images.md

File metadata and controls

58 lines (35 loc) · 2.54 KB

{{($page.frontmatter.start = 580) ? null : null}}

Images

Syntax for images is like the syntax for links, with one difference. Instead of link text, we have an image description. The rules for this are the same as for link text, except that (a) an image description starts with ![ rather than [, and (b) an image description may contain links. An image description has inline elements as its contents. When an image is rendered to HTML, this is standardly used as the image’s alt attribute.

Though this spec is concerned with parsing, not rendering, it is recommended that in rendering to HTML, only the plain string content of the image description be used. Note that in the above example, the alt attribute’s value is foo bar, not foo [bar](/url) or foo <a href="/url">bar</a>. Only the plain string content is rendered, without formatting.

Reference-style:

Collapsed:

The labels are case-insensitive:

As with reference links, whitespace is not allowed between the two sets of brackets:

Shortcut:

Note that link labels cannot contain unescaped brackets:

The link labels are case-insensitive:

If you just want a literal ! followed by bracketed text, you can backslash-escape the opening [:

If you want a link after a literal !, backslash-escape the !: