Earlier quoted context omitted.
I'm hoping the movement around ReasonML[0] could lead to both the web community being able to reap the benefits of OCaml's fundamentals, while also giving people a point of introduction to the OCaml community through web dev. It has been my experience that the ReasonML community is incredibly welcoming to new comers, and is moving at a break-neck pace to find the right target of being approachable for people who are…
I really don't understand why they had to invent a brand new syntax.
Type-safe GraphQL with OCaml
11–20 of 102 posts
Re: Type-safe GraphQL with OCaml
#12I wish OCaml had the libraries and community of Go or Rust, I think it'd be the most useful all-around language out there.
Re: Type-safe GraphQL with OCaml
#13Earlier quoted context omitted.
I really don't understand why they had to invent a brand new syntax.
The short answer is that Reason's syntax is simpler and more enjoyable to use. I simultaneously learned both OCaml and ReasonML syntaxes and find Reason to be much easier to work with. Perhaps people in Reason core will chime in with a more detailed answer. Here's some official information: https://reasonml.github.io/guide/ocaml/
I guess if you don't know OCaml, maybe the Reason syntax is more appealing.
Re: Type-safe GraphQL with OCaml
#14Earlier quoted context omitted.
Probably because they were first trying to sell an ML internally and it sounded like OCaml/Bucklescript didn't catch on. I think the new syntax is the raison d'etre to some extent.
Yes, many devs know stuff with C/Java/JavaScript like syntax.
Re: Type-safe GraphQL with OCaml
#15If ReasonML is able to form a real community, I have high hopes for its long-term prospects. Such an enjoyable language to use! I think their general approach of bootstrapping a community by lowering impedance with the JS ecosystem is a decent one. In case anyone on the OCaml team is reading this though, there are two language-level changes that I think could do wonders for wider adoption. The first is modular implic…
Re: Type-safe GraphQL with OCaml
#16I wish OCaml had the libraries and community of Go or Rust, I think it'd be the most useful all-around language out there.
Re: Type-safe GraphQL with OCaml
#17I wish OCaml had the libraries and community of Go or Rust, I think it'd be the most useful all-around language out there.
I wish OCaml could just use the libraries of Go and Rust. They can both compile to object files, and their type systems can be mostly modelled in OCaml's.
Re: Type-safe GraphQL with OCaml
#18If ReasonML is able to form a real community, I have high hopes for its long-term prospects. Such an enjoyable language to use! I think their general approach of bootstrapping a community by lowering impedance with the JS ecosystem is a decent one. In case anyone on the OCaml team is reading this though, there are two language-level changes that I think could do wonders for wider adoption. The first is modular implic…
I think the exact opposite. Finally a language where floats and integers cannot be mixed together accidentally.
Re: Type-safe GraphQL with OCaml
#19Earlier quoted context omitted.
I wish OCaml could just use the libraries of Go and Rust. They can both compile to object files, and their type systems can be mostly modelled in OCaml's.
OCaml can call external libraries via FFi functionality. I've only done this with Bucklescript (which makes it easy, the JS doesn't need to be compiled) though RWO walks through binding a C library: https://realworldocaml.org/v1/en/html/foreign-function-inter... . Wonder if this could be used with the go/rust compiler?
Re: Type-safe GraphQL with OCaml
#20It's an end-to-end way to type check REST API calls and responses using TypeScript.