-
Notifications
You must be signed in to change notification settings - Fork 0
/
layouts_index.re
73 lines (66 loc) · 1.7 KB
/
layouts_index.re
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
let text = ReasonReact.stringToElement;
[%raw "require('./index.css')"];
module Header = {
let component = ReasonReact.statelessComponent "IndexLayout Header";
let make _children => {
...component,
render: fun _self =>
<div style=(
ReactDOMRe.Style.make
background::"rebeccapurple"
marginBottom::"1.45rem"
()
)>
<div style=(
ReactDOMRe.Style.make
margin::"0 auto"
maxWidth::"960px"
padding::"1.45rem 1.0875rem"
()
)>
<h1 style=(ReactDOMRe.Style.make margin::"0" ())>
<Link
to_="/"
style=(
ReactDOMRe.Style.make
color::"white"
textDecoration::"none"
())
>
(text "Gatsby")
</Link>
</h1>
</div>
</div>
}
};
let component = ReasonReact.statelessComponent "IndexLayout";
let make children::(children: unit => ReasonReact.reactElement) _children => {
...component,
render: fun _self =>
<div>
<Helmet
title="Gatsby Default Starter"
meta=[|
{ "name": "description", "content": "Sample" },
{ "name": "keywords", "content": "sample, something" },
|]
/>
<Header />
<div style=(
ReactDOMRe.Style.make
margin::"0 auto"
maxWidth::"960px"
padding::"0px 1.0875rem 1.45rem"
paddingTop::"0"
()
)>
(children ())
</div>
</div>
};
let default =
ReasonReact.wrapReasonForJs
::component
(fun jsProps => make children::jsProps##children [||]);
let __esModule = true;