3 ms·
That you suggest Rust and Zig as alternatives suggests to me that you may not understand the requirements of a typical web application. These aren't usually CPU
by lolinder 3y ago
That you suggest Rust and Zig as alternatives suggests to me that you may not understand the requirements of a typical web application. These aren't usually CPU-bound apps that benefit from running close to the metal: the main bottleneck is DB queries and requests to other services. Adding all the complexity of the borrow checker isn't usually worth it unless your devs are already fluent in Rust, and using an early-stage C replacement like Zig would be an odd choice.
Here are the criteria I'd use for choosing a language for a web server, in order of importance:
1. What does my team already know?
2. What languages have a robust ecosystem of web-related libraries?
3. Static types are better than dynamic if the team is larger than 1 or if the project will last more than 6 months.
Performance considerations might come in after this if there are still two languages left to decide between. But judging from those criteria, I think you can see why TypeScript would not be a bad choice for a full stack web team.
- zelphirkalt 3y agoI find this kind of approach so limiting to a business in general. Basically you limit your choice of programming language and with that the ecosystem early on. You got 3 devs only knowing language X? OK cannot use any other language ever, because then they would have to learn something new (oh noes!). This will of course mean that additional developers also cannot apply their additional knowledge and will have to use the same language and ecosystem as the others, because they can't possibly be bothered to learn another language. Learning a new language should be a frequent thing. I don't know how many languages I have learned, but it has only ever increased my understanding of computer programming, advantages and disadvantages of approaches and it certainly has made me a better engineer. If a business does not want better engineers, sure, stick to the "we can only use what we already know!" approach. Let it take 2 weeks for people to learn a language! So what? It will pay off in the long run. You will have more experienced engineers, we have a less limited idea about computer programming and how to solve programming problems well, since they have gotten into contact with other concepts from other languages. You also get a more flexible team, that can accept building better and safer services, using the right tool for the job, instead of shoehorning everything into their only one language. You will open up more ecosystems for your whole business.