iamacup / react-native-markdown-display

React Native 100% compatible CommonMark renderer
MIT License
568 stars 167 forks source link

Noob question: Why is `FitImage` necessary? #156

Closed stopachka closed 9 months ago

stopachka commented 2 years ago

Hey team, this is less of an issue, but more of a question.

I am implementing some of my own markdown styles, and noticed I was having issues with images. Rendered by themselves, the "height" couldn't be figured out. I noticed that in renderRules, we use FitImage, which addresses this issue.

The question is, why is it necessary to use FitImage? What part of the renderer makes it, so the normal image can't figure out what height it should be?