1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/examples/with-reasonml/components/Header.re
Adam Lane 3d9564215c example with-reasonml dependency updates (#5048)
The original example fails to compile on my windows machine but updating bs-platform fixes that.
Depending on bs-next causes example to fail (package compiled with old incompatible version of bs-platform) so I have included it in a bindings directory where it can serve as an example of reason bindings.
Sources have been migrated to the latest reason-react.
2018-09-03 01:38:54 +02:00

17 lines
426 B
ReasonML

let component = ReasonReact.statelessComponent("Header");
let styles = ReactDOMRe.Style.make(~marginRight="10px", ());
let make = (_children) => {
...component,
render: (_self) =>
<div>
<Next.Link href="/">
<a style=styles> (ReasonReact.string("Home")) </a>
</Next.Link>
<Next.Link href="/about">
<a style=styles> (ReasonReact.string("About")) </a>
</Next.Link>
</div>
};