Reputation: 490
I am converting an old site to AMP-HTML and have an issue. Here is my code..
<ul>
<li><amp-img src="pic.png" layout="responsive" height="10" width="10"><h2>hello</h2></li>
</ul>
When I check it in the browser it pushes the image down and puts the h2 on top of the image.
Upvotes: 0
Views: 82
Reputation: 502
This is beacuse your <amp-img>
tag is not closed. close the tag as below.
<ul>
<li>
<amp-img src="pic.png" layout="responsive" height="10" width="10">
</amp-img>
<h2>hello</h2>
</li>
</ul>
This should work as I haven't encountered any issue with <amp-img>
tag as of now.
Upvotes: 2