Security News
New Python Packaging Proposal Aims to Solve Phantom Dependency Problem with SBOMs
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
reason-react
Advanced tools
ReasonReact is a safer, simpler way to build React components. You get a great type system with an even better developer experience. Why choose ReasonReact? Read more here
ReasonReact is just React.js under the hood. This makes it super easy to integrate with your current Next.js, Create React App, JavaScript, Flowtype or TypeScript project. Learn more about getting started here
Watch Ricky Vetter's Reason Conf talk, "Why React is Just Better in Reason" to learn more about how Facebook & Messenger are using ReasonReact
Watch Jordan Walke's Reason Conf talk, "React to the Future" to learn more about the future of ReasonML and React
/* Greeting.re */
[@react.component]
let make = (~name) => <h1> {React.string("Hello " ++ name)} </h1>
See all of our examples here. For a full application, check out reason-react-hacker-news.
BuckleScript is how your ReasonML code gets compiled to Javascript. Every project that uses BuckleScript will have a bsconfig.json
file (the same way you'd have tsconfig.json in a Typescript project) with project specific settings.
You can install BuckleScript globally or keep it project specific by adding it as a devDependency
:
yarn global add bs-platform
# or npm
npm install --global bs-platform
If you install BuckleScript globally, you can quickly generate a ReasonReact project template (similar to create-react-app
):
bsb -init my-react-app -theme react-hooks
cd my-react-app && npm install && npm start
# in another tab
npm run server
If you're interested in adding ReasonReact to your current project, it's a simple 2 step process:
yarn add bs-platform --dev --exact
# or npm
npm install bs-platform -D -S
Add the appropriate script tags to package.json:
"scripts": {
"re:build": "bsb -make-world -clean-world",
"re:watch": "bsb -make-world -clean-world -w"
}
Copy the bsconfig.json
file from our docs located here
Then add some files somewhere (don't forget to change bsconfig.json
, if needed).
The same way that TypeScript has type annotations
, we have bindings
. Bindings are libraries that allow you to import a popular project (like lodash) or to import your own local file. ReasonReact is in fact an example of a binding!
See https://reasonml.github.io/reason-react
We welcome all contributors! Anything from docs to issues to pull requests. Please help us :smile:
git clone https://github.com/reasonml/reason-react.git
cd reason-react
npm install
npm start
See the README inside src
for more info!
Looking for syntax highlighting for your favorite editor? Check out ReasonML Editor Plugins
FAQs
React bindings for Reason
The npm package reason-react receives a total of 560 weekly downloads. As such, reason-react popularity was classified as not popular.
We found that reason-react demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PEP 770 proposes adding SBOM support to Python packages to improve transparency and catch hidden non-Python dependencies that security tools often miss.
Security News
Socket CEO Feross Aboukhadijeh discusses open source security challenges, including zero-day attacks and supply chain risks, on the Cyber Security Council podcast.
Security News
Research
Socket researchers uncover how threat actors weaponize Out-of-Band Application Security Testing (OAST) techniques across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.