4 ms·
In functionality, roughly. By LoC, I think the majority of our codebase is still JavaScript/TypeScript. Many of the subsystems still in TS are being rewritten i
by ilikebits 3y ago
In functionality, roughly. By LoC, I think the majority of our codebase is still JavaScript/TypeScript. Many of the subsystems still in TS are being rewritten in Haskell (not because we have a "rewrite in Haskell" mandate, but because they are due for a rewrite anyway due to scale and requirement changes, and the team that owns that domain now primarily writes in Haskell).
- golergka 3y ago> Many of the subsystems still in TS are being rewritten in Haskell Have you tried fp-ts ecosystem? Code written in it looks pretty similar to Haskell, but it's still the same language, and you can gradually adopt it in the codebase instead of re-writing the whole thing. (I've also sent a question about personal professional development to your email from profile, hope this isn't abuse of your kindness here)
- CodeAndCuffs 3y agoFp-ts is one of like, 4 things in life I feel the need to shill for. It's docs are a little rough coming into it for the first time, and I think some of gcanti's tutorials are a little to complex. But I've slipped it into 3 or 4 moderate sized projects. Every time someone goes to touch it there's initial confusion, a 5 minute explanation of Either, 5 minutes of Q and A, and then they love it.
- golergka 3y agoThe only bad thing about this is, now that I've started writing functional code with it, I don't want to go back. I'm in-between jobs right now, and finding a company which utilizes it is a challenge.
- ilikebits 3y agoWe have, and it's Got The Spirit, but it's still not the same. It's just so much more verbose, so much noisier, and has so much less compiler safety. You don't get things like non-eager evaluation or effect tracking, your stack traces become much messier, and your open source dependencies are still in plain JS. Overall, we found that fighting against the language this way was the worst of both worlds - you paid a non-trivial cost and did not gain enough benefit. But our original codebase also predated TypeScript (remember TLDRLegal? That's us!), and much of our TS was bolted on after-the-fact on a pretty significant existing codebase that was written in very idiomatic JS. A team with more resources to do technical refactoring (we were quite small and very focused on building product) or starting from scratch may have a different experience.