HNHacker News
TopNewBestAskShowJobs

carllerche

1,816 karma · joined August 11, 2010

submissionscomments
carllerche··on Topcoat is pushing the boundary of server applications with Rust
Just needed a different name for it. What should it have been called? `#[component]` is not reachable from the client. We went with `#[shard]` to make it clear that it is different (callable from the client).
carllerche··on Topcoat is pushing the boundary of server applications with Rust
Of course there is. I consider there to be very little overlap. Axum is the router. You can do anything with it. API, web, whatever. Topcoat is a heavy layer on top focused on views.
carllerche··on Topcoat is pushing the boundary of server applications with Rust
Exactly my point. Everyone says agents are “best” at their language. Which probably translates to agents generate equally well for all programming languages. So, why would you not pick the programming language that gets you the best (fastest, least memory) end product?
carllerche··on Topcoat is pushing the boundary of server applications with Rust
That is in reference to the entire software industry. I’m not confident that we’re we’ll be building apps at all in 10 years vs just AI integrations
carllerche··on Topcoat is pushing the boundary of server applications with Rust
Do you have feedback on what you don’t like re: the migration system? It is inspired by drizzle. Is it something we missed or just not a fan of that style entirely?
carllerche··on Topcoat is pushing the boundary of server applications with Rust
Phoenix, HTMX, Data Star are all big sources of inspiration. Both HTMX and Data Star have built in support too.
carllerche··on Topcoat is pushing the boundary of server applications with Rust
The trend has been to move back to this style in general (see most modern JS frameworks). The main point is less about combining code and view, but breaking up the page into many small components and pushing data loading down into where it is needed vs up front.

Doing that enables a bunch of performance tricks like starting to steam the page before data i loaded and concurrently render components.

If you have to split your page into many small components, a separate view file for each becomes tedious.

carllerche··on Principles for Fast Tokio Applications
https://github.com/tokio-rs/tokio
carllerche··on HTML over WebSockets: real-time SPAs with barely any JavaScript
Topcoat (Rust) is aiming taking this approach as well: https://github.com/tokio-rs/topcoat. The project is still in the early days. It won't require WebSockets, but WebSockets will be an option.
carllerche··on Topcoat: A framework for building full-stack reactive web apps with Rust
I know the repo was posted here a few days ago (https://news.ycombinator.com/item?id=48952067). The intent was to open the repo at the same time as the blog post, but we ran out of private repo CI credits, so opened it up early and it got posted.

We still wrote the blog post. It provides a bit more context. Feel free to ask questions here.

carllerche··on Topcoat: The full full-stack framework for Rust
All on the roadmap :) topcoat-ui is already usable with Shadcn components (recent Pr: https://github.com/tokio-rs/topcoat/pull/118) we are still working on pulling in more components.

Re: OpenAPi you want to consume or provide an OpenAPI endpoint? I’m assuming you want to provide one. This is probably on the medium term roadmap after other stuff like UI, tighter ORM integration, email, etc…

carllerche··on Topcoat: The full full-stack framework for Rust
> Will have to see if Toasty solves it and whether it lets one query for arbitrary structs and add fields to structs from query results (e.g., in the README example for Toasty, explicitly joining on TODOs and mapping them to a simple field on the User objects as opposed to using ORM `has_many`)

I'm not 100% following. Feel free to ping me in discord (https://discord.gg/tokio) or open an issue on Toasty and we can dig into it. Toasty is also pretty new, but maturing fast.

The other points are valid. There are challenges with extracting params and a type system. This is how topcoat does it: https://docs.rs/topcoat/latest/topcoat/router/attr.path_para...

carllerche··on Topcoat: The full full-stack framework for Rust
Topcoat is entirely server rendered. Reactivity is added using attributes and other signals to a JS “runtime” shipped with topcoat. It is a similar idea to htmx/datastar/hotwire where as Leptos uses wasm to run rust in the browser as well as the server, more like nextjs or solidjs
carllerche··on Topcoat: The full full-stack framework for Rust
Depends on what you mean by that. Tokio the runtime is lean, and stable. Tokio the org is a collective of devs working on creating and maintaining a full ecosystem for building client and server apps with rust.
carllerche··on Topcoat: The full full-stack framework for Rust
The ORM is here: https://github.com/tokio-rs/toasty/. Tighter integration between the two is on the near-term roadmap.
carllerche··on Topcoat: The full full-stack framework for Rust
Both Loco and Topcoat aims to be "batteries included" but that means very different things to each project. Topcoat aims to make it easy to build reactive apps without writing any browser JS (or Rust). It uses a similar strategy to Hotwire, HTMX, Datastar, ... It also will default to using the Toasty ORM (though topcoat is modular so you a swap it out). Topcoat is very young and there is a lot more to build.
carllerche··on Topcoat: The full full-stack framework for Rust
Don't remind me... I'm old. (I was involved w/ Ruby on Rails in the early days)
carllerche··on Topcoat: The full full-stack framework for Rust
I don't take offense from differences in design opinion. The goal of topcoat is to be opinionated and not make everyone happy. And JS libs are a heavy inspiration. They do a lot right and have years of experience in the browser-app space. If you don't like it, Axum aims to be the lower-level HTTP router that anyone can build their own abstractions on top of.

That said, if you are up to it, I would ask that you try using it and provide your thoughts after using it as an issue. Feedback is appreciated.

carllerche··on Topcoat: The full full-stack framework for Rust
It's built: github.com/tokio-rs/toasty/, just not tightly integrated yet. That is on the roadmap.
carllerche··on Topcoat: The full full-stack framework for Rust
Yes, that is the goal. Those frameworks have a bit (more than a decade) head start though :) there is a lot to build.

There already is an ORM (https://github.com/tokio-rs/toasty/). You can see a sketch of the roadmap here: https://github.com/tokio-rs/topcoat/issues/104

carllerche··on Topcoat: The full full-stack framework for Rust
Roadmap: https://github.com/tokio-rs/topcoat/issues/104 ORM: github.com/tokio-rs/toasty

It is early, a lot is coming, but you can already build good stuff now.

carllerche··on Topcoat: The full full-stack framework for Rust
Migrations: Done with Toasty (https://github.com/tokio-rs/toasty/) which I intended to be integrated tightly with topcoat. You can see a rough roadmap here, which will be posted: https://github.com/tokio-rs/topcoat/issues/104

Better to ship early and hear what people want though :)

carllerche··on Topcoat: The full full-stack framework for Rust
I think it is highly likely topcoat / toasty will get split out. It is just work, especially since tokio-rs has more CI usage available than the default GitHub org.
carllerche··on Topcoat: The full full-stack framework for Rust
This will (very soon) integrate tighter with the Toasty ORM http://github.com/tokio-rs/toasty/. E.g. tight form -> record flow. We are shipping now though to get usage.

What pain points do you have in the Rust web framework ecosystem? Happy to hear.

carllerche··on Topcoat: The full full-stack framework for Rust
I didn't expect to see this here yet. We opened up the repo because we ran out of private CI usage. A blog post is coming next week :). Happy to answer questions here though.

One thing to keep in mind, the main reason for Topcoat to exist is that many organizations are already using Rust for infrastructure-level or performance sensitive reasons and often just want to build a web app using the programming language they already use.

carllerche··on My thoughts on the Bun Rust rewrite
Sounds like Andrew is using the same argument as Bjarne Stroustrup: if you use it right, you don't write bugs. It hasn't really worked out for C++.
carllerche··on Rewrite Bun in Rust has been merged
I don't think Rust vs. Zig has anything to do with why people are talking about this. It is a large piece of "real software" that underwent a full language transition in ~1 week using LLMs. That is a big deal regardless of the language and will be a case study regardless of how it turns out.
carllerche··on Bun's experimental Rust rewrite hits 99.8% test compatibility on Linux x64 glibc
> On the other hand, Rust is a complex language prone to refactoring avalanches, where a small change in a component forces refactoring distant code.

Are you saying this out of personal experience or just hypothesizing? I am working on a large, complex rust project with Claude Code and do not experience this at all.

carllerche··on Supply chain nightmare: How Rust will be attacked and what we can do to mitigate
The most common reason is that a quick manual step is needed before publishing. Nothing malicious. Often it is just removing paths used during dev from Cargo.toml. Should it be automated? Sure, but that is extra work.
carllerche··on Supply chain nightmare: How Rust will be attacked and what we can do to mitigate
I agree that position is nonesense. I mean, the single best defense against supply chain attacks is to bring everything in house. Is that reasonable? No…
Page 1 of 5Next →