First let me say that I do not hate Node or Javascript. There's nothing wrong with using Node to create server side applications or just plain console apps.This isn't a criticism: I'm genuinely curious as to why people use it over something like C#.The benefits of C# I see are:Strong vs. loose typing. It seems any time this is discussed people bring up that you can achieve stronger typing with Typescript, which is fine, but it's an extra layer that only makes it more Java / C#-like.Debugging: debugging Node in VSCode works but is nowhere near as robust as debugging C# in Visual Studio. Visual Studio's C# debugger is way more powerful; you can even edit code whilst debugging.Unit testing: writing unit tests in Visual Studio is simple. The tests are fast and debugging / TDD is a breeze. With Node even setting up Jest to enable debugging in VSCode was a pain - adding Babel to generate sourcemaps, fiddling with all the config options.. and finally, when it's running, it's slow (about 15s just to trigger a breakpoint on a basic test).Possible benefits I see of using Node:Possible to do functional-style programming rather than OOP.The JS community is strong with lots of packages available.Working with a documentDB like Mongo is more natural than it is with C#So what's the appeal? Is it just because JS is the most popular language and it's easy for JS devs to pick up?
Submitted September 22, 2020 at 11:29AM by qa-account
No comments:
Post a Comment