17

I'm having such a blast writing code in TypeScript. Once you learn it you cannot go back to regular JavaScript.

Comments
  • 2
    What in particular do you like about it vs plain JavaScript? I haven't looked into it, old heard others talk.

    How is it any better than say, latest js features w/ babel? Not a rhetorical question, I'm just curious about the experience.
  • 5
    @Wisecrack it is mostly types, I get a bunch of information by just reading typed code, and my tooling have it easy because the guessing game is out of the picture, one example: Was using query-string to parse location.search this as part of a function that returns a string, without typing safeguarding my dumbass I could have return an array of strings instead of a string (was using the result of parsing location.search).

    Small stuff like that can (and should) be caught by having unit tests in place, but I find it helpful that Emacs can highlight those, I can fix them right away, all thanks to types.
  • 2
    @catholic-emacs sounds better than than little help we get now. Js I'm finding is notoriously fast and loose.
  • 3
    @Wisecrack like a diarrhea
  • 0
    @molaram lol
  • 2
    @molaram I mean, you can still use JSDoc to get proper intellisense. Good luck importing types with that though.
Add Comment