I am using jquery for ajax in the build of a test app whilst learning react.
Is it possible to use to jquery selector as the target to render react components?
This is from the react tut.:
React.render(
<FilterableProductTable products={PRODUCTS} />,
document.getElementById('content')
);
This does not work but i don't even know if it is possible:
React.render(
<FilterableProductTable products={PRODUCTS} />,
$('#content')
);
Thanks, John
This will do the trick
React.render(
<FilterableProductTable products={PRODUCTS} />,
$('#content')[0]
);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With