Hi all!
I will be up front with you all, I am not a Rust developer. However, I have been honing my skills working with AI agents to work on the code writing, with very specific and thorough architectural boundary rules. I developed this robust system utilizing a language I do know (TypeScript) and I wanted to run an experiment. This experiment was basically: is my process well-defined enough that it works in a language I don't actually know?
Background: I have become interested in Rust because I wanted to take a look at coding languages that are far more efficient than ones like JavaScript or Python. To further this, I am looking to port a TypeScript side project of mine into full stack Rust, using Dioxus for the frontend. Furthermore, this UI needs a table library (currently using AG grid in the TypeScript code). I figured that I would try writing my own table library in Rust using the aforementioned process I've created to force-multiply using AI. I am aware a few already exist, but I wanted to try to create my own, specifically one that supported Dioxus integration and virtualization, which I could not find an existing alternative for, among the options.
The agents ran some investigative routines before reporting to me the findings of the Rust standards and tradeoffs. After investigating these one by one I created a set of instructions for it to follow in creating this library. And after development and regression testing, I will say that it appears to be working fully as I intended it to, unit tests and all. However, I am well aware of the gap of simply trusting output code without knowing the language, so I am asking if anyone in this domain could review the output Rust and ensure that a couple of things hold:
-
Is the error handling and layer separation idiomatic?
-
The implementation chose the `Arc<dyn Fn(&Row) -> CellValue>` accessor pattern, is this the right call?
-
Does the virtualization approach look sound?
-
Are there API ergonomics that would feel un-Rusty to a native?
I found one limitation I deferred, the data pipeline recomputes per render on scroll rather than memoizing on scroll-only changes, would love thoughts on whether deferring that is sound.
I do intend to learn Rust more myself, once I have the time. The scope for this though, was the experiment, not my skills in the syntax.
I invite brutal feedback on this code. Thank you!
Github repository: GitHub - zernst3/rust-chorale: A headless, type-safe table library for Rust with adapters for Dioxus and other frameworks. TanStack Table for Rust. ยท GitHub