I know Rust alright, and I like it. I’d rather write TypeScript for most web applications and I write good and solid TypeScript a lot faster than I do Rust. (Helps that I can easily write the same language and use many of the same libraries on my frontend, too.)
If you're creating a frontend web app to go along with it there are others, such as reduced context–switching and using fewer tools.
Frankly, a sample size of one is incredibly weak evidence that it's faster to develop using one technology than another. If you glance through the author's Twitter/GitHub it's also clear that he works with Rust significantly more than he does with Node, which makes this particular sample even more suspect.
I liked this article since I always wanted to see concrete numbers or at least a general idea.
It's not uncommon for business to move from Ruby/Python/JavaScript to Go as they grow. I personally preferred learning Rust over Go because of its depth.
I really feel like we really need to reconsider what "minimalist" means in the js ecosystem.
That said, it probably means minimalist in a usage sense. Compared to things like Nest.js (which I love, don't get me wrong), express is a lot more straightforward and basic.
> full = full == "true";
Umm.. Why?
> if (!!limit
Not not limit? Is this due to some corner case conversion for JS to make 100% sure this gets into a boolean..?
I'm sure both samples have its reasoning, I'm just not aware. Any help please?
[1]: https://stackoverflow.com/questions/5971645/what-is-the-doub...
That's basically a way to convert a stringified bool to a bool. Not the way I'd do it, and "assignee_name, summary, limit" are all declared as reassignable just to be able to reassign "full".
> if (!!limit
That's pretty common in js, not usually in if statements, but in other cases. No idea why that was done that way.
When you send ?full=true in a query, your req.query object is { full: "true" }. It's not going to assume it can deserialize arbitrary strings.
A more interesting question is:
As a CTO: Why would or wouldn't you choose Rust over Java, Node or Go?
Rust is not a new language (started in 2006, 1.0 Release in 2015). Why is its adoption kind of disappointing compared to its technical value?
The answers are not even more benchmarks or another even more wicked zero cost abstraction async runtime.
I'd like to read stories about some real world adoption. Can your average Java or Go devs become proficient in Rust in a reasonable amount of time? Is the code really mostly maintaince free, once it has compiled? Would it have been cheaper to just add some more servers to handle the load? How about large teams working on large domains (Java land)?
I tried to make changes and run his benchmarks, however the DB seeding is in Rust and it fails to compile on my machine....
Rust is really fast, especially compared to Node. This is an easy benchmark to win. So why not use a framework that's actually secure.
Your claims about being dead are wildly exaggerated and misleading.
You're in NYC as am I. The Rust NYC meet-up is a great way to connect and learn more.
I’d say they’re outdated. The project after the original author was frustrated with some in the community, found a way to allow the project to continue, which is overall good, but still a very disappointing episode.
https://github.com/expressjs/express/tree/5.0
https://github.com/expressjs/express/pull/4196
https://github.com/expressjs/express/issues/2761
If someone is doing a new project in node I would recommend: https://github.com/fastify/fastify
https://github.com/hapijs/hapi
In the above benchmark, fastify would probably narrow the gap. https://www.fastify.io/benchmarks/