Real world demo app with jsoo-react #120
Replies: 2 comments 3 replies
-
Nice! This will be very useful for both testing and showcasing I think.
Any reason you're not also considering using |
Beta Was this translation helpful? Give feedback.
-
Main reason is that
This is not only applicable to network requests with There was an interesting conversation in https://discuss.ocaml.org/t/json-encode-decode-in-js-of-ocaml/8539/12. Still, even with all these advantages, I still have the impression that bundle size increases way too much than what it should with the encoders/decoders generated by |
Beta Was this translation helpful? Give feedback.
-
Hey 👋
I migrated @jihchi Real World demo app to jsoo-react:
https://github.com/jchavarri/jsoo-react-realworld-example-app
Initially the main purpose was to measure bundle size (which I will be doing and publishing results next), but in the end it turned out to be a great way to test jsoo-react in some close to real scenario, and see the kind of things that were missing.
In general I'd say the experiment is quite successful, here are some highlights:
data-xxx
attributes can be improved, but it's possible (see with_test_id.ml)fetch
were missing, implemented frombs-fetch
(thanks @glennsl and contributors), see fetch.mlirequire("foo")
calls, see markdown.mliThe readme contains installation instructions. It uses very simple approach to bundling with Webpack.
Let me know what you think, or if there are any improvements or questions. Maybe this can serve as baseline to measure bundle size over time, test API proposals etc. :)
Beta Was this translation helpful? Give feedback.
All reactions