react has become
incredibly popular, and the ecosystem around react is
robust. reactR aims to allow R users to more
easily incorporate react and JSX.
install.packages("reactR")
# for the latest development version
# install from Github
# devtools::install_github("timelyportfolio/reactR")
Let’s use react to render a simple h1 HTML
element below.
## Warning: package 'htmltools' was built under R version 4.3.3
For more on how we can use R and React, see the blog post React in R. Also, there are many more examples in the Github repo at inst/examples.
JSX
helps ease some of the burden caused by
React.createElement. reactR provides a
babel_transform() function to use JSX.
Hopefully, in the future, we can convince RStudio to modify
htmltools to work directly with JSX (see issue).
Need a high-speed mirror for your open-source project?
Contact our mirror admin team at info@clientvps.com.
This archive is provided as a free public service to the community.
Proudly supported by infrastructure from VPSPulse , RxServers , BuyNumber , UnitVPS , OffshoreName and secure payment technology by ArionPay.