I am using React-pdf to show a pdf viewer from html on my website. I can easily show the rich text editor value in HTML. But can't show it in pdf viewer using react-pdf. In HTML I just used below code to retrieve data from rich text editor.
<div dangerouslySetInnerHTML={{__html:responseData.paymentMethod}}/>
Basically rich text data is saving like this in DB:
<ol><li>abc<br></li><li>efg<br></li><li>hij<br></li></ol>
But react-pdf don't support any HTML tag like Div or others, it supports XML. If i write like this
<Text dangerouslySetInnerHTML={{__html:responseData.paymentMethod}}/>
It don't get any result.
I searched google, but I didn't get any convenient answer. Any help regarding this would be appreciated or if there is any alternative way to show rich text data into normal text, please inform me.