ReasonReact bindings for akiran/react-highlight
npm install @cnguy/bs-react-highlightReasonReact bindings for react-highlight.
State: Published
* With yarn
``yarn add @cnguy/bs-react-highlight`
* With npm
`npm install --save @cnguy/bs-react-highlight`
Add @cnguy/bs-react-highlight to bsconfig.json bs-dependencies.
Add a highlight.js theme.
For example:
`html`
rel="stylesheet"
type="text/css"
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css"
/>
Implicit:
`reason
let component = ReasonReact.statelessComponent("App");
let code = "
function helloWorld() {
console.log('Hello, world!')
}
";
let make = _children => {
...component,
render: _self =>
};
`
Explicit:
`reason
let component = ReasonReact.statelessComponent("App");
let code = "
print(\"Hello, world!\")
";
let make = _children => {
...component,
render: _self =>
};
`
innerHTML:
`reason
let component = ReasonReact.statelessComponent("App");
let code = "
let make = _children => {
...component,
render: _self =>
};
`
Release
`sh``
yarn start # npm run start