Live data from Hacker News

Farewell, Rust for web

yieldcode.blog

161–170 of 197 posts

Re: Farewell, Rust for web

#161
post #32

the idea of one language to rule them all is very compelling. it’s been promised a lot, and now everyone hates Java. but the truth is that Rust is not meant for everything. UI is an abstraction layer that is very human and dynamic. and i can come and say, “well, we can hide that dynamism with clever graph composition tricks” à la Elm, React, Compose, etc, but the machinery that you have to build for even the simplest…

How much of that is just because Rust UI libraries are not ready, though? It's never going to become Python, but it could become decent.

Re: Farewell, Rust for web

#162
post #9

The TS/React ecosystem is so mature, it's hard for Rust to compete with it. My optimal stack is currently: Rust on the backend, Typescript/React for web with OpenAPI for shared types.

What's a better alternative for shared types? OpenAPI is really outdated and the tooling is always a mess.

There is ts-rs [1], but it's only for TS.

[1]: https://docs.rs/ts-rs/latest/ts_rs/

Re: Farewell, Rust for web

#163

Rust shines in user-space systems-level applications (databases, cloud infrastructure, etc.) but definitely feels a bit out of place in more business-logic heavy applications.

You must have meant something else because it's also great at business logic.

Re: Farewell, Rust for web

#164
post #132

Earlier quoted context omitted.

I mean somebody could make a singular rust dependency that re-packages all of the language team's packages. But what's the threat model here. Does it matter that the Rust STD library doesn't expose say "Regex" functionality forcing you to depend on Regex [1] which is also written by the same people who write the STD library [2]? Like if they wanted to add a back-door in to Regex they could add a backdoor into Vec. Pe…

> I mean somebody could make a singular rust dependency that re-packages all of the language team's packages. That's not the requirement though! Curation isn't about packaging, it's about independent (!) audit/test/integration/validation paths that provide a backstop to the upstream maintainers going bonkers. > But what's the threat model here. A repeat of the xz-utils fiasco, more or less precisely. This was a succe…

Isn't xz-utils exactly why you would want a lot of dependencies over a singular one?

If say Serde gets compromised then only the projects depending on that version of Serde are as opposed to if Serde was part of the std library then every rust program is compromised.

> That mistake has bitten NPM repeatedly already, and the reckoning is coming for Rust too.

Eh, the only things that coming is using software expressly without a warranty (expectantly) will mean that software will cause you problems at an unknown time.

Re: Farewell, Rust for web

#165

Earlier quoted context omitted.

java didn't have an http client (I guess it had a url 'stream') for the longest time and STILL doesn't have an http server.

It has one - it’s been a part of the JDK for a while https://docs.oracle.com/en/java/javase/11/docs/api/jdk.https...

sun is typically not available anymore / deprecated even and not available in the JRE or it's early access, but fair point.

Re: Farewell, Rust for web

#166

Earlier quoted context omitted.

java didn't have an http client (I guess it had a url 'stream') for the longest time and STILL doesn't have an http server.

Not really? Iirc `HttpUrlConnection` has been around since the 90s?

I did mention that, but for a lot of things it is not enough compared to a full http client most stdlib's have. HttpClient was introducted for a reason.

Re: Farewell, Rust for web

#167

Earlier quoted context omitted.

java didn't have an http client (I guess it had a url 'stream') for the longest time and STILL doesn't have an http server.

java didn't have an http client [...] and STILL doesn't have an http server. Wow. How long has it been since you guys have used Java? Serious question?

I tried to implement a minimal server just to realize that there is still no way to do so in java 21... I stand corrected I guess it was recently added: https://docs.oracle.com/en/java/javase/25/docs/api/jdk.https..., but it's a sun package instead of standard RT - but probably because it is still early.

Re: Farewell, Rust for web

#168
post #59

I find the dependency creep for both rust and node unfortunate. Almost anything I add explodes the deps and makes me sweat for maintenance, vulnerabilities, etc. I also feel perpetually behind, which I think is basically frontend default mode. Go does the one thing I wish Rust had more of which is a pretty darn great standard library with total backwards compatibility promises. There are awkward things with Go, but m…

The dependency creep keeps on happening in web frameworks where ever you look. I was thinking of this quote from the article: > Take it or leave it, but the web is dynamic by nature. Most of the work is serializing and deserializing data between different systems, be it a database, Redis, external APIs, or template engines. Rust has one of the best (de)serialization libraries in my opinion: serde. And yet, due to the…

> I know of one person who got fired from a project due to no small fact that building the system he was presented with took > 24 hours when a full build was triggered, and this happened every week.

Incremental Nix builds can take less than 1 munute to build everything, including the final deployable docker image with a single binary on very large Haskell codebases. That fact the the person was fired for everybody around him systematically failing to admit and resolve a missing piece of supportive infrastructure for the engineering effort of one person tells a lot about the overall level of competence in that team.

> but ultimately it is a failing of the "everything and the kitchen sink" philosophy at play in dependency usage.

Not really, as the kitchen sink only has to build once per its version change, for all future linkage with your software for the entire engineering team doing the builds in parallel.

Re: Farewell, Rust for web

#169
post #151

Earlier quoted context omitted.

if we trim a regex down to literal character matches is it still a regex?

So any text file is a programming language?

I would say that a "language" is a necessary component of a "programming language".

An empty file was an IOCCC winner: https://www.ioccc.org/1994/smr/ but you need to interpret that empty file as C source in order to reasonably claim to have programmed the computer.

My reasoning comes more from the other direction: someone who writes HTML is programming therefore HTML is a programming language.

Post reply on HN