Hi everybody, as you can see in the title I am trying to convert react component to pdf, after all of the libraries felled, I choose to send to the backend after getting the component out of the DOM, the problem is I must to convert it to string and send it by axios to the node backend, but I don’t know what to do from here, all of NPM modules work only with HTML files, anybody know how to convert this file back to HTML file? or any other solutions?
What do you mean by “covered a React component to pdf”? Do you mean seeing what you see in the browser? That is so dependent on the browser and what data is being fed to the component - I don’t think you can separate the two. It’s like asking how to bring your lap with you when you stand up. I think you néed a screen capture of a specific implementation. That is graphical data. Then if you have to send it to the backend you can either sand a file or send it as data by encoding it in base64.