5 ms·
Rust Web Framework Comparison
- chatterhead 4y agoThese are the kinds of things that make me think, "Do you really need Javascript or C++ or Haskell anymore?" Can't we just use Rust from top to bottom for pretty much everything?!
- paulgb 4y agoWe can! It’s a lot of work because you don’t have the whole JS ecosystem to fall back on, but to some that’s a feature not a bug. My favorite example of this is https://makepad.dev https://makepad.dev
- Mikeb85 4y agoI mean, Unix/Linux was top to bottom C for a long time. It still kind of is. Higher level languages aren't needed per se, but they do make life easier.
- Existenceblinks 4y agoUntil Rust shows me lightweight binary size story.
- fleventynine 4y agoThe language itself is lightweight enough to use on tiny microcontrollers. Most bloat on the host side comes down to your choice of dependencies (clap is one of the worst offenders in my experience, bloating a simple command line tool by as much as 10x in both size and compile time).
- rascul 4y agoI wonder if there's an alternative to clap's derive stuff? I really love it (I think it came from structopt), it makes defining and handling the arguments nice and easy when things get a bit complex.
- haskellandchill 4y agoRust and Haskell present a very different programming experience, and so does an untyped language like JavaScript. Just because you can program in Rust for web development doesn't mean developers will want that type of experience. The C++ comparison makes more sense since Rust presents that style of programming done better.
- wongarsu 4y agoYou absolutely can. The biggest snag in "rust everything" is in web frontends. Yew is decent, but getting JavaScript developers is so much easier than getting Rust developers who like (web) frontend work.
- skohan 4y agoIt's also just a matter of the massive amount of prior art available on the JS side. There's so much you would have to create from scratch in Rust which is already an npm package.
- KAKAN 4y agoIf you think about it, the reason Rust, or any other programming language were created, was simply because other languages had something lacking... There's no single language that's the greatest. Haskell has different aims than Rust. If you're using Haskell for frontend development, you probably need to reconsider your choices, I think
- Waterluvian 4y agoYou can with basically any language. But it would likely be a bad idea. You will eventually have created such an abstraction that you’ve got a new language. Django is written in C after all. ;)
- rascul 4y agoGitHub says it's 97.1% python and doesn't list C. https://github.com/django/django https://github.com/django/django
- Waterluvian 4y agoMy tongue in cheek joke is that CPython is C. And if you write long enough in Rust something that needs plenty of flexibility, you’ll end up inadvertently writing a language.
- nequo 4y agoOh, like Greenspun’s tenth rule: > Any sufficiently complicated C or Fortran program contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of Common Lisp.
- Waterluvian 4y agoHah I’ve never seen that one. Love it!
- skohan 4y agoI'm not convinced Rust would ever be the right "everything language". Currently I find myself reaching for it for almost every domain, largely thanks to the ADT's and amazing tooling, but it's a bit low level and sometimes tedious for certain sets of applications where more approachable languages, like Python and JS currently are the standard bearers. Personally I think we would get really far with Rust, and some yet-to-exist higher level language with a modern type system built on top of the Cargo ecosystem. Then maybe C and/or something like Zig for niche applications where extreme memory efficiency is the main constraint.
- reducesuffering 4y agoHave you tried writing a web backend in Rust? See Primeagen, a Senior Eng at Netflix w/ Rust as his #1 lang, and his experience writing a quick web backend in Go, Rust, and TS: https://youtu.be/Z0GX2mTUtfo?t=267 https://youtu.be/Z0GX2mTUtfo?t=267
- lemper 4y agoto be quite honest, this kind of evangelism is what drives me away from rust.
- heromal 4y ago
- andrewmcwatters 4y agoThis isn't a comparison... this is a series of lists.
- deleted 4y ago[deleted]
- hutrdvnj 4y agoThat makes me wonder if there is a web framework for Haskell that compiles to WASM.
- belmont_sup 4y agoHaskell has a garbage collector, and the wasm gc proposal has just hit stage 3. Once and if this continues and gets implemented, then we’ll see how Haskell (and fingers crossed, ocaml) gets compiled to wasm. I’d love to deploy Haskell or ocaml on some of these new cloud wasm hosts.
- tazjin 4y agoCurious why rouille (my personal server-side favourite) is marked as "outdated". Because it doesn't use async? That's the point! It had a release fairly recently (less than 3 weeks ago) and works perfectly fine with a pretty stable API. Edit: I opened a PR to fix it! https://github.com/flosse/rust-web-framework-comparison/pull/150/ https://github.com/flosse/rust-web-framework-comparison/pull...
- andrewmcwatters 4y agoBecause it's an undisciplined collection of many people's hard work, boiled down to overly simplistic attributes used to highlight some repositories and put others down.
- hn92726819 4y agoThat doesn't mean it's outdated. You might be right or wrong about your point, but that's what comparisons are for. That's like saying "I refuse to compare Linux to windows because windows is bad"... Not helpful for anyone actually wanting the differences
- bpicolo 4y agoI think they are referring to this comparison repo, rather than the framework
- ofrzeta 4y agoI was confused for some minutes because the first hit when I googled "rouille rust" is "rouille (French for Rust) is here to save your day, as it allows you to write Rust programs in French, using French keywords, French function names, French idioms." with code like: statique mutable DICTIONNAIRE: PeutÊtre<Dico<Chaine, Chaine>> = Rien; That's probably "Option" in English Rust?
- ttfkam 4y agoPeut être: "Maybe"/"Perhaps" Literally: "Could be"
- anxiously 4y agoI tried to enjoy rust and make a service with it to give it a test run. I really disliked the reliance on so many third party libraries to get things done. Is this not possible using the standard library alone?
- rascul 4y agoSure, you can write the stuff yourself instead of using a third party library. Might be harder than it sounds, though.
- bobbylarrybobby 4y agoIf you make a tree of crate dependencies, the root is the standard library. So yes, you could build it all yourself with the standard library, it would just be really unpleasant. I agree, it would be nice the if the rust foundation would give their blessing to some important crates like serde and regex, but putting them in the standard library only makes them harder to evolve. In particular, breaking changes go from being unpleasant to disallowed altogether.