News for hackers. Stuff that matters.
Re:Ask HN: What are your favorite developer-efficiency tips? by ggregoire on Friday May 08, 2020 @11:54PM (#23122161)
> The investment you have to make to really grok static typing is quite large. It took about 2 years for me to be really comfortable in TS.

That sounds a bit exaggerated from my experience. If anyone interested in TS got discouraged reading your comment, it took between like 2 days and 2 weeks for my team to be really comfortable in TS. If you already know JavaScript and if you already have some experience with statically-typed languages, TS is literally JS with static types.

Re:Ask HN: What are your favorite developer-efficiency tips? by city41 on Saturday May 09, 2020 @12:25AM (#23122312)
Maybe my choice of the word "comfortable" was incorrect (although I would say "grok" was a spot on word choice in this context). It took me a good while to get the point where no matter what I encounter in TS, I feel pretty confident I can arrive at understanding it. The type system is very powerful and there are some deep rabbit holes you can find yourself in.

For example, if you can follow this blog post after only two weeks then you are much smarter than me: https://medium.com/free-code-camp/typescript-curry-ramda-typ.... This is a pretty extreme example, but sometimes you hit crazy types or crazy type errors like this.

But I would agree it doesn't take all that long to feel comfortable enough with TS to be productive with it.

Re:Ask HN: What are your favorite developer-efficiency tips? by ggregoire on Saturday May 09, 2020 @01:00AM (#23122438)
Interesting article. :)

And there is a useful library linked at the end: https://github.com/pirix-gh/ts-toolbelt.

Re:Ask HN: What are your favorite developer-efficiency tips? by lostmsu on Saturday May 09, 2020 @12:12AM (#23122252)
To be fair, TypeScript's typing is very overloaded with stuff, and is much more complicated than Java or C#'s.
Re:Ask HN: What are your favorite developer-efficiency tips? by deathtrader666 on Saturday May 09, 2020 @04:03AM (#23123031)
Hence my love for ReasonML / OCaml with the Bucklescript compiler.
Re:Ask HN: What are your favorite developer-efficiency tips? by rhlsthrm on Saturday May 09, 2020 @05:01AM (#23123204)
Do you use ReasonML on the backend as well? Or just something like ReasonReact? I've been interested in Reason and still wondering the best way to work it into my NodeJS/React/Typescript stack.
Re:Ask HN: What are your favorite developer-efficiency tips? by itsArtur on Saturday May 09, 2020 @06:41AM (#23123616)
I am not parent comment's author, but I use TS on the backend and I did look into ReasonML. I love most of Reason's syntax and FP in general, but unfortunately, reason/bucklescript ecosystem just isn't mature enough for a serious project. I'd recommend against using it unless you are in some megacorp and you can afford to build general-purpose tooling.
Re:Ask HN: What are your favorite developer-efficiency tips? by mekster on Saturday May 09, 2020 @06:00AM (#23123434)
Doesn't mean it's hard to get started. It only means, if you want to type everything to the detail, you can do it.