FAQ: How to add an image?
When you are editing the _README.md_ file of the given repository templates, you may need to upload images.
You can use one of the following methods for it.
Option 1: Using MD image format
You can upload images to a folder inside your GitHub page folder (Ex:
/docs/images/ folder) and add the relative URL of the image as below.
![Sample Image](./images/sample.png)
Figure 1.1 Sample Image
Option 2: Using HTML + Bootstrap CSS classes
You can upload images to a folder inside your GitHub page folder (Ex:
/docs/images/ folder) and add the relative URL of the image as below. You can also use any
Bootstrap-4 CSS classes to format the image.
<div class="figure container">
<img class="mx-auto d-block" src="./images/sample.png" alt="Sample Image" width="128" />
<p class="caption text-center">Figure 1.1 Sample Image</p>
</div>
Option 3: Using drag-and-drop upload
If you are editing the
/docs/README.md in the GitHub web, you can just drag and drop the image into the text editor, and it will be automatically uploaded to GitHub CDN and provide you a link like below. You can use either
Option 1 or
Option 2 with this link.
![github](https://user-images.githubusercontent.com/11540782/118809291-0e6e1f00-b8c8-11eb-8bd7-66af735c50c5.png)