#Hello, how can I export the "Render" to html ? (I'm using ReactJS)

1 messages · Page 1 of 1 (latest)

formal frigate
#

🥹

neat bane
#

You can use react’s renderToStaticMarkup method

formal frigate
neat bane
#

You want react output as a string rather than HTML output?

formal frigate
#

yes, yes something like that

#

or HTML output that include css and js in file

neat bane
#

React output is hard, essentially part of https://github.com/measuredco/puck/issues/302

But it sounds like you're probably better off using renderToStaticMarkup and separately distributing your CSS and JS via a bundler. However, this is very much a user-land problem to solve and will vary depending on your setup

GitHub

Puck should explore support for multi-framework support, including: Vue.js Svelte -> Insert other JS framework here <- Considerations The host application is React The components API is React...

formal frigate
#

ok, I'll try it, thank you

tribal ibex
#

@formal frigate were you able to achieve it??

formal frigate
#

no I still can't achieve it @tribal ibex