Skip to content

Instantly share code, notes, and snippets.

@uupaa
Last active August 30, 2024 21:03
Show Gist options
  • Save uupaa/f77d2bcf4dc7a294d109 to your computer and use it in GitHub Desktop.
Save uupaa/f77d2bcf4dc7a294d109 to your computer and use it in GitHub Desktop.
image resize in github flavored markdown.

Image source

https://gyazo.com/eb5c5741b6a9a16c692170a41a49c858.png

Try resize it!

  • ![](https://gyazo.com/eb5c5741b6a9a16c692170a41a49c858.png | width=100)

  • ![](https://gyazo.com/eb5c5741b6a9a16c692170a41a49c858.png =250x250)

  • ![](https://gyazo.com/eb5c5741b6a9a16c692170a41a49c858.png)

    • Copy <img> in browser DevTools. Replace ![](url) to <img>. Add width(and height) attr.
    • <img src="https://camo.githubusercontent.com/..." data-canonical-src="https://gyazo.com/eb5c5741b6a9a16c692170a41a49c858.png" width="200" height="400" />

Other information

@mjbear
Copy link

mjbear commented Aug 12, 2024

alt{: width="50%"}

Still does not work in github repo readme. The {: width="50%"} part just does ignore.

The syntax for images with a specified width has changed over time.

HTML image tags are the way to go

@AndrianD
Copy link

height="450px" works for me. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment