2 things to edit
The problem is, maybe you haven't setup URL in _config.yml file that's why incomplete URL making some troubleshoots. You need 2 things to do!
- URL Set-up
- Image Tag Set-up
URL Setup
In _config.yml just add 2 lines:
#_config.yml url: 'https://your-github-username.github.io/' # your main domain baseurl: 'your-repo-name/' # if you're using custom domain keep this blank example: baseurl: ''
Now we are all set with our URL setup, now edit anchor tag or link tag in post1.md file.
Image Tag Set-up
Let's dive into your image tag which is in markdown formate like:

edit into this:
<img src="{{site.baseurl | prepend: site.url}}assets/Untitled.png" alt="Untitled" /> <!-- OR --> <img src="{{ "/assets/Untitled.png" | prepend: site.baseurl | prepend: site.url}}" alt="Untitled" />
Here:
- {{...}} is a Liquid filter syntax
- site.url is collecting URL from the
_config.yml file - site.baseurl is collecting baseurl to add that after the url for GitHub Pages
- **| prepend: ** is a filter which means site.url will be added before the site.baseurl. this tag will render this:
<img src="https://your-github-username.github.io/your-repo-name/assets/Untitled.png" alt="Untitled" />
That's it. I Guess this will help to do your work perfectly. Fact is this answer was already given by me in: https://stackoverflow.com/a/67733921/14387700
...
HAPPY JEKYLLING