News for hackers. Stuff that matters.
Re:JavaScript Structs by EraYaN on Friday October 11, 2024 @06:39AM (#41808229)
At least in C# you can ignore most of it and the complexity doesn't really come from numerous foot guns. You can still write Java 1.6/.NET 2 style C# code just fine, it's all there. The rest of the features can be fully ignored and they won't hurt you.

But then again the newer features they do make writing code a lot nicer, giving more compile time analysis warnings etc hopefully resulting in slightly better code. And the new features also enabled a lot of performance improvements in the runtime which is nice. .NET 2/4 wasn't all that fast, .NET 8 can be a lot faster.

Re:JavaScript Structs by rezonant on Friday October 11, 2024 @06:59AM (#41808356)
You can still write ES5 and it will work in the latest JS runtimes, so I'm not sure how this is different.

Further, indeed the newer JS features do in fact give you better compile time analysis, warnings, etc, and result in slightly better code.

Re:JavaScript Structs by niutech on Friday October 11, 2024 @08:46PM (#41815394)
You can even write ES3 and it should work in all web browsers.