5 ms·
They've "won" so far because static types languages were cumbersome and unpleasant to use, but this is changing and dynamic languages are learning some type tri
by blub 6y ago
They've "won" so far because static types languages were cumbersome and unpleasant to use, but this is changing and dynamic languages are learning some type tricks too.
The issue here is with Rust: its strengths are mostly irrelevant for the web and its weaknesses (particularly slow development compared to the competition because of having to pacify the type checker) are really important.
Op is painstakingly beating around the bush, but what they're getting at is that Rust + webdev = mismatch.
- cageface 6y agoExactly. The frameworks aren't there yet but I think Typescript is pretty much ideal for web dev. We're still using dynamic languages for web dev for mostly legacy reasons now.
- cies 6y agoNot sure if "ideal" is a good choice of word here. We dont know what's still coming. It surely has some flaws (many inherited from JS). There is stuff like ReasonML/Elm/PureScript that seems more ideal to me from a pure language (not eco sys, job/talent market, etc) perspective.
- cageface 6y agoYeah sure there are many better languages than TS in an absolute sense but TS is the only one I see with the momentum to displace the current incumbents.
- te_chris 6y agoIt's still a single threaded run time. There's one platform that's ideal for web, BEAM, but unfortunately it doesn't have a strongly typed language. Elixir and Erlang are both great languages though.
- Multicomp 6y agoI can't speak to whether or not the BEAM is ideal for the web, but I will say I've been watching the Gleam project very closely because having static typing with the BEAM is a dream of mine.
- staticassertion 6y agoI don't totally agree about its strengths not being relevant. Memory safety is an extremely low bar that the web has generally managed to meet, but Rust has a lot of value elsewhere. The author talks about significant performance improvements, which would be very welcome on many sites, as well as improved error handling and data validation patterns.
- blub 6y agoMost things thank goodness are not SPAs, nor do they have to be. The problem here is the concept of SPA itself - it's a complete hack which is plastered over with various tricks to make it halfway usable. This has been going on for years now. Websites on the other hand are slow because of the tracking and the ads which load tons of JS. Remove that and the web will be blazing fast.
- heavyset_go 6y ago> Remove that and the web will be blazing fast. With sufficient ad blocking and JS white listing, I can attest to this. After removing ads and analytics, sites that rely on JavaScript to render significant amounts of content are the slowest.
- XCSme 6y agoIf you have A LOT of content (eg. a table with 10000 rows containing rich data) it will be faster to use a JS virtualized list than to just have all those 100k+ DOM elements computed at once.
- jfkebwjsbx 6y agoFor a lot of "usual" webdev, any reasonably modern language will do. Even modern JavaScript will be fine. Something like C# would have been way better, though, but we cannot change that now. However... software development has become a mess of slow technologies and abstractions one on top of the other. Some people are working routinely in a text editor that is behind three operating systems: the VM/hypervisor, the usual operating system (Windows/macOS/Linux) and then a browser instance (which is like a operating system now). Then add all the drivers, libraries, frameworks etc. that go in-between. While I don't like that WebAssembly is yet another abstraction, at least it is a chance for a resurgence of system programming languages and to proper software engineering...
- tracker1 6y agoWhy can't you use C#? .Net Core (upcoming .Net 5) are pretty decent to work with. I'd still rather use node for the most part though. I have been playing with Rust, but not sure about how good an idea it is for the front end yet though.
- jfkebwjsbx 6y agoWell, you can compile the .NET runtime into Wasm, send it to the client and run C# on top of it, but then you are adding yet another layer.
- tracker1 6y agoI didn't have the impression the discussion was a web context. In which case if lean straight js/react or rust/yew
- swebs 6y agoPretty sure the parent comment was talking about client side.
- LandR 6y agoYou can use C# on the front end now with Blazor. It's pretty new though so I don't know how good it is yet.
- collyw 6y agoI think they have "won" in certain domains. Java and C are still widely used in loads of places, though less so in web dev.
- blargmaster33 6y ago"static types languages were cumbersome and unpleasant to use" Can not disagree more! Dynamic languages are by there verry nature inferior to statically typed.
- ashkante 6y agoI am currently writing a hobby project in Rust with Rocket and Diesel. I could bang out a working prototype very quickly with either Python or something like ASP.NET, but I picked Rust because I want to get better at it. Many of the things you say are true - Rust libraries in general need some love and polish before they can be beginner-friendly, but some are getting there. The difference between Diesel and Rocket, for example, is quite stark. The former has only the barest minimum 'examples' and 'guide', if they may be called that, and I feel like I'm expected to read and understand its source code to become really proficient with it. It takes a lot of experimenting and trial+error to do anything beyond the basics. Rocket, on the other hand, has a very comprehensive guide with useful examples and, so far, has been enjoyable to work. That said, there are still a lot of "convenience" features missing. My current notable example is forms. As I'm doing it (I haven't looked into any addons to Rocket for this), I have to write out the HTML for the form myself, along with any Javascript I might require for validation, etc, then write the server-side methods for GET/POST, making sure to maintain the state myself. In this regard, something like Django's effortless ease to get a form on screen and store its data into a database really showcases where Rust (Rocket) still has a long way to go. Hopefully, with more people using it, the tools and libraries will improve and mature, particularly the documentation. When all is said and done, I enjoy "slogging" through Rust a lot more than I did working with Django, even with the slower progress. Something about this language really speaks to me.