if you think of any questions about ReScript between now and then, don't hesitate to drop us a comment (here, discord, email, whatever is easiest for you!)
so Rob is going to be returning to the stage in August to do a followup on ReScript. this next talk will be more about how they're using ReScript at Autobooks, but if you have any followup questions, reply to this comment and we'll be sure to get your questions into the next video!
sounds like a dream. wow. do you use them together in the same app, or just side-by-side for different elements (ReScript for the frontend, F# for the backend, maybe?)?
@@MichiganTypeScript I wish. I mean I just moved my personal projects to F# now. Not yet sure what to do with ReScript. Fable makes F# easy to use on the frontend.
I remember trying to pick up ReasonML before typescript took off. The support for it was minimal across IDEs and trying to use it was painful. I dropped it and assumed Reason died a few years ago. Calling a typescript competitor the Reasonml successor is just bad branding. No one wants to use reasonml, dont associate with it. But we do need a faster and open source version of something that is like typescript.
> No one wants to use reasonml, dont associate with it. > But we do need a faster and open source version of something that is like typescript. not arguing (asking humbly): these back-to-back statements seem contradictory. Is it just that you don't like ReScript or that you _do_ like ReScript and want to break any associations between ReScript and ReasonML?
we feel the same way: we'd love to see more content on this area and are crossing our fingers that the MiTS community won't hate it. after all: it's really something TypeScript developers might be interested in and can benefit from (we think... we'll see if we're right!).
thanks for presenting this. I think that TypeScript is a mashed together little monster and it is meh at best. But OCaml derivatives like Rescript need a lot of promotion to get out there, and talks like this look to be a part of it.
would you agree that, ultimately, it's JavaScript that's the mashed together little monster and TypeScript makes it more bearable (although, we understand the "lipstick on a pig" vibes some people get from it)? And thanks: we really want to surface things like ReScript (and others!) because of the whole "rising tide lifts all boats" thing.
same... I think it's a big misconception with types is that it pays off compared to the investment. my observations (and I was dealing with types even before typescript - back when google closure compiler was using es4-like types) is that the overall benefit does not contend the extra effort.
Rob really is a treasure! Do you use (or hope/plan to use) ReScript? Even if not: anything you'd like to hear when Rob shows his company's codebase in the next talk?
@@MichiganTypeScript maybe monorepos could help, but I usually works with huge codebase, where is context is really important. And I can have same names in different contexts. And this contexts can be nested. I leaved it when monorepos was something new, it was 2020 if I am corrent
@@MichiganTypeScript how the code is structured, in kotlin functions we can omit the open and closing bracket and all the logic will be inside as a scope of it and the last item will be returned as a value... You could Google and see how it is or to save some time just google for how to use "when expression in kotlin" and you will realize what I want say🙂🙂
33:54 dear god what even is that syntax. Let statements inside an object closure? No thanks. 55:08 "Sometimes typescript forces you to code defensively". Yeah, that's actually a good thing. Defensive coding/early returns is a GOOD pattern not a bad one. I'm glad this wasn't adopted. That looks like an absolute nightmare.
Let statements inside block scope is an intrinsic feature of JavaScript. However when the same thing is done in ReScript as shown in 33:54 it's a no no for you? Double standards. Give it a chance before you spread negativity.
ReScript is not a sucessor to ReasonML. ReasonML does native. ReScript does not. I used to use Reason for native applications. Melange is a sucessor to Reason.
this came up on twitter: thanks for the clarification. it's genuinely hard to get all of this straight: we're hoping that someone from the ReScript/ReasonML/Melange camps (even one person!) will accept our very-genuine offer to make a quick video breaking it all down, but no bites yet (although some people did some good stuff trying to whiteboard it).
23:30 this kind of elite speak ("polymorphic variant") can easily be avoided (even "sum type" or "product type" would have been better) Scott Wlaschin has demonstrated many times that you can teach fp concepts with no gobbledygook
It’s not elite, it’s just unfamiliar. OOP has tons of jargon for example, and it’s not labeled as “elite”. It’s also a different concept from a “sum type” (and especially from “product type”)
@@MichiganTypeScript Great question! Here's how I think about it: A sum type is a type-level "OR". If a `foo` type is either A | B | C - it has 3 possible states (that's where the "sum" part comes from, 1 + 1 + 1). In typescript terms, this is a discriminated union. A product type is your typical struct/record found in almost all languages, in the case of JS that would be an object. It's called "product", because you have to multiply (cartesian product) all the combinations of the fields to get the number of states. If you have a record User with 3 boolean fields, it would have 6 possible states (2x2x2). A polymorphic variant is similar to a sum type, but solves certain problems where you'd want to use the same variant constructor in multiple places. Probably best to refer to Rescript and OCaml docs for more details, I don't think I can do them justice in this format :) ocaml.org/manual/5.2/polyvariant.html rescript-lang.org/docs/manual/latest/polymorphic-variant
@@MichiganTypeScript A sum type is basically like an enum, an enumeration type has a limited/fixed number of variations, for example TimeOfDayEnum = PM | AM or LedEnum = Red | Green | Blue. In type theory, a type with a fixed number of variants goes by "sum type". The idea is that the total number of possible values for this type is simply the sum of its variants. TimeOfDayEnum has 2 possible values and LedEnum 3. A product type, on the other hand, is more like a record. For example, a Coordinate record can have entries for X and Y. Coordinate(X, Y). The number of possible values for Coordinate is the product of all possible values for X and Y, i.e., X times Y. Hence, the name product type (for example, Coordinate has 2 x 3 = 6 possible values for values int X = 1..2 and int Y = 1..3). Sum types and product types go also by the name Algebraic Data Type (ADT). Algebraic is math speak for types that combine. Example: take Person(Name, AgeCategory) where AgeCategory = Minor | Adult. Person is a product type combined with a Name and a sum type. Sum Type can also consist of other sum types or product types. Deeply nested or recursive Sum Types and Product types are possible too (json). In OCaml, sum types are also called Variants. For polymorphic variants google up "Polymorphic vs. ordinary variants in OCaml" (Yehonathan Sharvit).