File tree Expand file tree Collapse file tree 3 files changed +30
-58
lines changed
Expand file tree Collapse file tree 3 files changed +30
-58
lines changed Original file line number Diff line number Diff line change @@ -40,16 +40,16 @@ Demonstrate how to use the React JSX PPX
4040
4141 function X$App (Props) {
4242 return Belt__Belt_List.toArray(Belt__Belt_List.map({
43- hd: "Hello!",
44- tl: {
45- hd: "This is React!",
46- tl: /* [] */0
47- }
48- }, (function (greeting) {
49- return JsxRuntime.jsx("h1", {
50- children: greeting
51- });
52- })));
43+ hd: "Hello!",
44+ tl: {
45+ hd: "This is React!",
46+ tl: /* [] */ 0
47+ }
48+ }, (function (greeting) {
49+ return JsxRuntime.jsx("h1", {
50+ children: greeting
51+ });
52+ })));
5353 }
5454
5555 const App = {
@@ -60,5 +60,7 @@ Demonstrate how to use the React JSX PPX
6060
6161 JsxRuntime.jsx(X$App , {});
6262
63- exports.App = App;
63+ module.exports = {
64+ App,
65+ }
6466 /* Not a pure module */
Original file line number Diff line number Diff line change 2424 const React = require("react");
2525
2626 const cb = React.useCallback((function (a, b) {
27- return a + b | 0;
28- }), []);
27+ return a + b | 0;
28+ }), []);
2929
30- exports.cb = cb;
30+ module.exports = {
31+ cb,
32+ }
3133 /* cb Not a pure module */
3234
3335Using an Uncurried function:
@@ -45,9 +47,11 @@ Using an Uncurried function:
4547 const React = require("react");
4648
4749 const cb = React.useCallback((function (a, b) {
48- return a + b | 0;
49- }), []);
50+ return a + b | 0;
51+ }), []);
5052
51- exports.cb = cb;
53+ module.exports = {
54+ cb,
55+ }
5256 /* cb Not a pure module */
5357
You can’t perform that action at this time.
0 commit comments