I found that the "best" way is to use HTML, as it works both in Readme/.md files and also in comments (within Issues, Gist...)
E.g. when adding/editing a comment (within Issues, Gist...) :
- Upload the picture by drag-and-drop in the text field
- replace
![image](https://your-image-url.type)
with<img src="https://your-image-url.type" width="100" height="100">
As mentioned by @cbestow (thanks!), it's not mandatory to set both width
and height
. If only one is set, the other will be adjusted accordingly to preserve the aspect ratio of the image.
can confirm it works well, thank you.![](https://private-user-images.githubusercontent.com/145142603/315616417-2e551f1f-3d91-4ad2-b57c-e7a760061045.jpg?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE3MDE5MDYsIm5iZiI6MTcyMTcwMTYwNiwicGF0aCI6Ii8xNDUxNDI2MDMvMzE1NjE2NDE3LTJlNTUxZjFmLTNkOTEtNGFkMi1iNTdjLWU3YTc2MDA2MTA0NS5qcGc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwNzIzJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDcyM1QwMjI2NDZaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0xYjBhOTFjZTM3ZWJhMGJjMWE5NTI1NjAyMDk5MTVlODMwYzRkOGFlNWEyM2IxZmU3MWNkMzQ0ZGI4M2JjM2Q1JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.GFG8fp1zTx747_GaGNNwGX_q3g5nga3pBGZEA6KFAdI)