File tree 7 files changed +21
-2
lines changed 7 files changed +21
-2
lines changed Original file line number Diff line number Diff line change @@ -10,3 +10,6 @@ node_modules
10
10
* .bs.js
11
11
* .re.js
12
12
.bsb.lock
13
+
14
+ # GenType output
15
+ * .gen.tsx
Original file line number Diff line number Diff line change 24
24
"suffix" : " .bs.js" ,
25
25
"bs-dependencies" : [" reason-react" , " bs-css" ],
26
26
"namespace" : true ,
27
- "refmt" : 3
27
+ "refmt" : 3 ,
28
+ "gentypeconfig" : {
29
+ "language" : " typescript" ,
30
+ "debug" : {
31
+ "all" : false ,
32
+ "basic" : true
33
+ }
34
+ }
28
35
}
Original file line number Diff line number Diff line change 6
6
],
7
7
"scripts" : {
8
8
"start:bs" : " bsb -make-world -w" ,
9
- "build:bs" : " bsb -make-world" ,
9
+ "build:bs" : " export BS_CMT_POST_PROCESS_CMD= \" gentype \" && bsb -make-world" ,
10
10
"clean:bs" : " bsb -clean-world" ,
11
11
"start:playground" : " cd packages/playground && npx webpack-dev-server"
12
12
},
13
13
"devDependencies" : {
14
14
"bs-platform" : " ^4.0.7" ,
15
+ "gentype" : " ^1.0.0" ,
15
16
"lerna" : " ^3.3.0"
16
17
}
17
18
}
Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ module Styles = {
30
30
] );
31
31
};
32
32
33
+ [@ genType ]
33
34
let make = children => {
34
35
... component,
35
36
render: _self => <button className= {Styles . button() }> ...children </button >,
Original file line number Diff line number Diff line change 15
15
"license" : " MIT" ,
16
16
"dependencies" : {
17
17
"bs-css" : " ^7.4.0" ,
18
+ "gentype" : " ^1.0.0" ,
18
19
"react" : " ^16.2.0" ,
19
20
"react-dom" : " ^16.2.0" ,
20
21
"reason-react" : " >=0.4.0"
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ let component = ReasonReact.statelessComponent("Button");
2
2
3
3
let s = ReasonReact . string;
4
4
5
+ [@ genType ]
5
6
let make = _children => {
6
7
... component,
7
8
render: _self => <input type_= "checkbox" />,
Original file line number Diff line number Diff line change @@ -2735,6 +2735,11 @@ genfun@^5.0.0:
2735
2735
resolved "https://registry.yarnpkg.com/genfun/-/genfun-5.0.0.tgz#9dd9710a06900a5c4a5bf57aca5da4e52fe76537"
2736
2736
integrity sha512-KGDOARWVga7+rnB3z9Sd2Letx515owfk0hSxHGuqjANb1M+x2bGZGqHLiozPsYMdM2OubeMni/Hpwmjq6qIUhA==
2737
2737
2738
+ gentype@^1.0.0 :
2739
+ version "1.0.0"
2740
+ resolved "https://registry.yarnpkg.com/gentype/-/gentype-1.0.0.tgz#6f6b91a08e878711cde46eaecda0f287deae65b6"
2741
+ integrity sha512-2ta+Ei8V66Ghx3q+RA20KtXrhtKeVtAB7OZ75nDq2tjUbnqGrVQMb3BkWm4DQt0Y00M64uEIeXLTGdGBr4F5cg==
2742
+
2738
2743
get-caller-file@^1.0.1 :
2739
2744
version "1.0.3"
2740
2745
resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a"
You can’t perform that action at this time.
0 commit comments