omnilib / sphinx-mdinclude

Markdown extension for Sphinx
https://sphinx-mdinclude.omnilib.dev
MIT License
21 stars 11 forks source link

Modify relative image/link paths #7

Open Details0824 opened 2 years ago

Details0824 commented 2 years ago

Using mdinclude to embed the .md document outside the document can display docstring and other content, but when there is a relative path in the md file to display the image, the image cannot be read. Code show as below:

<div align="center">
   <img src="../../img_path.png" >
</div>

The image can be read by modifying the path to read the image relative to the path of the document where the mdinclude command is located, but how to display the image without changing the image read path in the .md file.