react-native-htmlview
react-native-htmlview copied to clipboard
Unordered List followed by Paragraph not rendering properly
Consider the following html:
<html><body><ul><li>Item 1</li></ul><p>Paragraph</p><p>P2</p></body></html>
Expected output:
- Item 1
Paragraph
P2
Actual output:
- Item1Paragrah
P2
Check Android and IOs at the this Snack Link
I would expect a new paragraph to be started after the list. As is the case for html rendered in the browser.
Hacky Solution:
- Manually add newlines after list
- while (html.indexOf("ul><p") > -1) { html = html.replace("><p", ">\n\n<p"); }
Hi, I'm also facing some issue when trying to render ul li html tags, is there any solution or workaround ?
In my case, the workaround has been to add line breaks (<br />) to the markup. The main issue for me seems to be the formatting of the list when sandwiched between paragraphs.
for me, a list of ul > li with many li tags breaks