Is there a way to render a solid component to html string from the browser?
I want to send raw html string to another service where it gets printed as a pdf. The renderToString functions dont work on the browser and I get 'computation outside of render' errors when I run the component function and try to convert it to string. Do I need to port the project to SolidStart in order to achieve this or is there a way to do it inside the browser?
2 Replies
maybe
(<Component/>).outerHTML
? https://playground.solidjs.com/anonymous/28b572fa-de23-4018-a251-58d89295925eSolid Playground
Quickly discover what the solid compiler will generate from your JSX template
Thanks! that worked as expected