fosstodon.org is one of the many independent Mastodon servers you can use to participate in the fediverse.
Fosstodon is an invite only Mastodon instance that is open to those who are interested in technology; particularly free & open source software. If you wish to join, contact us for an invite.

Administered by:

Server stats:

10K
active users

#reasonml

0 posts0 participants0 posts today
Felix 🇺🇦🚴‍♂️🇨🇦🇬🇱🇩🇰🇲🇽🇵🇦 🇪🇺<p><span class="h-card" translate="no"><a href="https://types.pl/@disconcision" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>disconcision</span></a></span> <a href="https://norden.social/tags/hazel" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>hazel</span></a> looks interesting. Not heard of yet. </p><p>Hazel is a live functional-programming environment rooted in the principles of type theory.</p><p><a href="https://hazel.org/" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">hazel.org/</span><span class="invisible"></span></a></p><p><a href="https://github.com/hazelgrove/hazel" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">github.com/hazelgrove/hazel</span><span class="invisible"></span></a></p><p><a href="https://norden.social/tags/functionalprogramming" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>functionalprogramming</span></a> <a href="https://norden.social/tags/elm" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>elm</span></a> <a href="https://norden.social/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> <a href="https://norden.social/tags/ocaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ocaml</span></a></p>
Harley Eades<p>Okay, so I've got a new codebase as well. I'm switching over to <a href="https://hci.social/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> for my backend development. This will make it super easy to prop up a website along with my backend interface (on <a href="https://hci.social/tags/nodejs" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>nodejs</span></a>) to my database. Then I can run experiments and testing using the backend interface before launching the mobile app. Learning a lot!</p>
J. David Eisenberg<p><span class="h-card" translate="no"><a href="https://fosstodon.org/@rauschma" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>rauschma</span></a></span> What is your opinion of <a href="https://tech.lgbt/tags/ReScript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReScript</span></a> (<a href="https://rescript-lang.org/" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">rescript-lang.org/</span><span class="invisible"></span></a>)? It has somewhat an <a href="https://tech.lgbt/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a> heritage via <a href="https://tech.lgbt/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a></p><p>Edit: Just looked at the source for Grain; it’s mostly ReasonML!</p>
Artemis<p>So basically, it looks like the best way would be to:<br>1. Declare DTO types with *all* the fields (maybe using combining types if you use Rescript)<br>2. From these combined types, manually construct "entity" types. If needed, you can use composition (through records, tuples, etc) to combine multiple entities together.</p><p><a href="https://toot.cafe/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> <a href="https://toot.cafe/tags/Rescript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Rescript</span></a> <a href="https://toot.cafe/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a></p>
Artemis<p>2. OCaml has proper OOP, with inheritance, method overrides, all that stuff. But, unlike records, it's not easy to bind to JS objects, I think.<br>3. Somewhere on Rescript forum I saw something like "prefer explicitness to DRY". Which I guess makes sense?</p><p><a href="https://toot.cafe/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> <a href="https://toot.cafe/tags/Rescript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Rescript</span></a> <a href="https://toot.cafe/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a></p>
Artemis<p>What I think about it after some digging and poking around Melange and Rescript playgrounds:</p><p>1. Rescript can "combine" both object types and record types. If you have `type t1` and `type t2`, a `type t = {...t1, ...t2}` will have fields from both t1 and t2. But you can't put a variable of `type t` where a `t1` or `t2` is expected. At least this doesn't work: <a href="https://tinyurl.com/yv7j24mj" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">tinyurl.com/yv7j24mj</span><span class="invisible"></span></a></p><p>{cont}<br><a href="https://toot.cafe/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> <a href="https://toot.cafe/tags/Rescript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Rescript</span></a> <a href="https://toot.cafe/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a></p>
Artemis<p>A question about ReasonML/Rescript/OCaml on JS.<br>How do you deal with the lack of structure inheritance?</p><p>I'm mainly a backend dev with OOP background so I'm probably not seeing something.</p><p>But at work, our frontend has a lot of types (TS) like this:</p><p>```<br>type Client = BaseClient &amp; {<br> assignees: Actor[]<br>}<br>```</p><p>We use these for types that we get from API (a base type + some additional fields).</p><p>How would you model something like that in Reason/Rescript/OCaml?</p><p><a href="https://toot.cafe/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> <a href="https://toot.cafe/tags/Rescript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Rescript</span></a> <a href="https://toot.cafe/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a></p>
Artemis<p>Okay, am I understanding this correctly?<br>1. You can't just use any NPM package in <a href="https://toot.cafe/tags/Melange" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Melange</span></a>, you need to find compatible (as in, OCaml/ReasonML) packages?<br>2. You can't just put a JS file into Melange and be able to require it and use any code from it?</p><p><a href="https://toot.cafe/tags/ocaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ocaml</span></a> <a href="https://toot.cafe/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a></p>
Sean<p>I wish <a href="https://dice.camp/tags/rescript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>rescript</span></a> had first-class monads 😭 I need my &gt;=&gt;<br>At the very least bring back online module opening syntax from <a href="https://dice.camp/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> and <a href="https://dice.camp/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a> 😔</p><p><a href="https://dice.camp/tags/haskell" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>haskell</span></a> <a href="https://dice.camp/tags/programming" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>programming</span></a> <a href="https://dice.camp/tags/functionalprogramming" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>functionalprogramming</span></a></p>
John Haley<p><span class="h-card" translate="no"><a href="https://fosstodon.org/@xyhhx" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>xyhhx</span></a></span> I used to host <a href="https://mastodon.haley.io/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> meetups in <a href="https://mastodon.haley.io/tags/phx" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>phx</span></a> </p><p>What are you using nowadays?</p>
John Haley<p>Time for an <a href="https://mastodon.haley.io/tags/introduction" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>introduction</span></a> </p><p>I'm John and quite new to the <a href="https://mastodon.haley.io/tags/fediverse" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>fediverse</span></a> but this feels like how the internet was back in the 90's and I love it.</p><p>My partner is not on <a href="https://mastodon.haley.io/tags/mastodon" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>mastodon</span></a> but we've been together for over 2 decades. We have 2 high energy girls that are delightfully weird.</p><p>I love <a href="https://mastodon.haley.io/tags/fitness" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>fitness</span></a> and I have been a <a href="https://mastodon.haley.io/tags/powerlifter" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>powerlifter</span></a> for over 10 years with various success.</p><p>I am a <a href="https://mastodon.haley.io/tags/FunctionalProgrammer" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FunctionalProgrammer</span></a> and write <a href="https://mastodon.haley.io/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> <a href="https://mastodon.haley.io/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a> at Ahrefs.</p><p>I'm 1 half of the duo that made GitKraken and was the VPoE at Qwick</p>
λ Francesco Serra λ<p><span class="h-card" translate="no"><a href="https://hachyderm.io/@dolanor" class="u-url mention">@<span>dolanor</span></a></span> <span class="h-card" translate="no"><a href="https://fosstodon.org/@rollbrettklauen" class="u-url mention">@<span>rollbrettklauen</span></a></span> Indeed <a href="https://fosstodon.org/tags/Haskell" class="mention hashtag" rel="tag">#<span>Haskell</span></a> is a powerful language, as well as <a href="https://fosstodon.org/tags/OCaml" class="mention hashtag" rel="tag">#<span>OCaml</span></a>, as <a href="https://fosstodon.org/tags/Scala" class="mention hashtag" rel="tag">#<span>Scala</span></a> (but I understand you want to avoid the JVM). As far as tooling is concerned, all of them have some level of incidental complexity though. There&#39;s also <a href="https://fosstodon.org/tags/PureScript" class="mention hashtag" rel="tag">#<span>PureScript</span></a>, which is a dialect of Haskell that transpiles to JavaScript, <a href="https://fosstodon.org/tags/ReasonML" class="mention hashtag" rel="tag">#<span>ReasonML</span></a> (dialect of OCaml), and ScalaJS (which still suffers from the same tooling of its parent). Funnily enough, the only language with a low complexity tooling wise is Elm</p>
Gabriela Noriega 🏳️‍⚧️ 🇧🇷<p><a href="https://tech.lgbt/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> looks cool af! I need to find some project to use it on.</p><p><a href="https://reasonml.github.io/en/" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="">reasonml.github.io/en/</span><span class="invisible"></span></a></p>
pospi 🏳️‍⚧️<p><span class="h-card"><a href="https://toot.lgbt/@iyalei" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>iyalei</span></a></span> right?! Actually I think it's just comforts and the false promises of being able to hack something together quickly that infect all of the imperative programming world. You have to remember a lot of JavaScript folks learned C or Java first, or were trained by others who did.<br>I wish we could bring <a href="https://hachyderm.io/tags/FlowType" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FlowType</span></a> back too but Facebook gave up on it to build <a href="https://hachyderm.io/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> and since there are <a href="https://hachyderm.io/tags/Rust" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Rust</span></a> UI frameworks now we might as well fall forward to coding in a proper ML with real type safety 😂</p>
Ben<p><span class="h-card"><a href="https://fosstodon.org/@rauschma" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>rauschma</span></a></span> I use <a href="https://mastodon.social/tags/ReScript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReScript</span></a> every day at work, so I understand the language very well, but I simply cannot get past the <a href="https://mastodon.social/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a> syntax. I find it incredibly hard to read. It would not surprise me if that were one of the main reasons it has not been adopted more widely.</p><p><a href="https://mastodon.social/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> was a solution to that but the waters got muddied and I’m not clear now on how usable that project still is.</p>
Schlez<p><span class="h-card"><a href="https://mastodon.social/@oriSomething" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>oriSomething</span></a></span> Slow compilation is extremely difficult for good web development. The incremental compilation speed in OCaml is very very very very good. Anyway it just tickles my interest, I've been very distant from <a href="https://hachyderm.io/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> ever since I touched Rust but I have a warm place for it in my heart 😁</p>
Mark Derricutt (talios)<p><span class="h-card"><a href="https://mastodon.social/@wfaler" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>wfaler</span></a></span> <a href="https://mastodon.nz/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> looked interesting - then kinda forked to <a href="https://mastodon.nz/tags/ReScript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReScript</span></a> (<a href="https://rescript-lang.org" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="">rescript-lang.org</span><span class="invisible"></span></a> - which is just the buckle script layer) and it’s direction got confusing from the outside.</p><p> Maybe I should just start looking at <a href="https://mastodon.nz/tags/FSharp" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FSharp</span></a> and .NET</p>
Programingisthefuture<p><span class="h-card"><a href="https://hachyderm.io/@sbr" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>sbr</span></a></span> <a href="https://qoto.org/tags/ocaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ocaml</span></a> have a lot of use cases, it have great support to build compilers (it was used to build <a href="https://qoto.org/tags/rust" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>rust</span></a>). It's used by <a href="https://qoto.org/tags/mirageos" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>mirageos</span></a> and multiple other cool projects. It can be used to do frontend application with <a href="https://qoto.org/tags/reasonml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reasonml</span></a> or ocaml_of_js. OCaml can build rest APIs and much more... <a href="http://ocamlverse.net/content/ecosystem.html" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">http://</span><span class="ellipsis">ocamlverse.net/content/ecosyst</span><span class="invisible">em.html</span></a></p>
Fran<p><span class="h-card"><a href="https://hachyderm.io/@sbr" class="u-url mention" rel="nofollow noopener noreferrer" target="_blank">@<span>sbr</span></a></span> I was once really, really, really hyped with <a href="https://hachyderm.io/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> <a href="https://reasonml.github.io/" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="">reasonml.github.io/</span><span class="invisible"></span></a> but never ended up using it for real... although I know it has some real users, like <a href="https://v2.onivim.io/" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="">v2.onivim.io/</span><span class="invisible"></span></a> for example.</p><p>And there's also <a href="https://reasonml.github.io/reason-react/" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="ellipsis">reasonml.github.io/reason-reac</span><span class="invisible">t/</span></a>, which is cool.</p><p>And it is all based in <a href="https://hachyderm.io/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a></p>
Sophia Brandt :vim:<p>What I like about <a href="https://hachyderm.io/tags/Svelte" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Svelte</span></a> is that it works with <a href="https://hachyderm.io/tags/RxJS" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>RxJS</span></a> out of the box. It's no fluff and easy to get started with.<br>What I like about <a href="https://hachyderm.io/tags/SolidJS" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>SolidJS</span></a> is that it's reactivity that makes sense.<br>What I like about <a href="https://hachyderm.io/tags/Angular" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Angular</span></a> is that it works great with teams and has a rock-solid architecture, forces me to use <a href="https://hachyderm.io/tags/TypeScript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>TypeScript</span></a>, plus <a href="https://hachyderm.io/tags/RxJs" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>RxJs</span></a> .</p><p>btw:<br>I'm still sad about <a href="https://hachyderm.io/tags/ReasonML" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReasonML</span></a> - I liked that a lot (<a href="https://hachyderm.io/tags/OCaml" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OCaml</span></a> for <a href="https://hachyderm.io/tags/Frontend" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Frontend</span></a> - way better than TS!). But the ecosystem was too small, plus the switch to <a href="https://hachyderm.io/tags/ReScript" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ReScript</span></a> hurt.</p>