Space between html tags is huge even tho I wrapped my content in "<div>"
nikita-zot-1408 opened this issue · 5 comments
nikita-zot-1408 commented
I have very big distance between elements even tho I have my code like this.
<HTMLView
value={`<div>${currentPostDetails?.text.replace(
/<br\\?>|\r?\n\s*/g,
'',
)}</div>`}
stylesheet={checkTheme ? webViewStyleLight : webViewStyleDark}
/>
My content is still displayed like this:
Any suggestions on how to solve this please?
akenarong999 commented
Got this problem too. Any solution?... pls.
yestay90 commented
the same is here.
daveyjones commented
You need to add addLineBreaks={false}
.
MohdUmer commented
when use addLineBreaks={false} height still to huge... any solution?
joemewes commented
I had this also, even with addLineBreaks={false}
. I found lots of null in RootComponent element
with a children data value of '\n\n'. Don't have time to fully debug but a temp fix for me was to add the following in my custom renderNode
function.
if (node.data === '\n\n') {
return null;
}