[HN Gopher] We rewrote our Rust WASM Parser in TypeScript - and ...
       ___________________________________________________________________
        
       We rewrote our Rust WASM Parser in TypeScript - and it got 3x
       Faster
        
       Author : zahlekhan
       Score  : 30 points
       Date   : 2026-03-20 21:48 UTC (1 hours ago)
        
 (HTM) web link (www.openui.com)
 (TXT) w3m dump (www.openui.com)
        
       | blundergoat wrote:
       | The real win here isn't TS over Rust, it's the O(N2) -> O(N)
       | streaming fix via statement-level caching. That's a 3.3x
       | improvement on its own, independent of language choice. The WASM
       | boundary elimination is 2-4x, but the algorithmic fix is what
       | actually matters for user-perceived latency during streaming.
       | Title undersells the more interesting engineering imo.
        
         | shmerl wrote:
         | More like a misleading clickbait.
        
         | sroussey wrote:
         | Yeah, though the n^2 is overstating things.
         | 
         | One thing I noticed was that they time each call and then use a
         | median. Sigh. In a browser. :/ With timing attack defenses
         | build into the JS engine.
        
         | Aurornis wrote:
         | > Title undersells the more interesting engineering imo.
         | 
         | Thanks for cutting through the clickbait. The post is
         | interesting, but I'm so tired of being unnecessarily
         | clickbaited into reading articles.
        
         | socalgal2 wrote:
         | same for uv but no one takes that message. They just think
         | "rust rulez!" and ignore that all of uv's benefits are algo,
         | not lang.
        
       | dmix wrote:
       | That blog post design is very nice. I like the 'scrollspy'
       | sidebar which highlights all visible headings.
       | 
       | Claude tells me this is https://www.fumadocs.dev/
        
         | sroussey wrote:
         | Interesting, thanks. I need make some good docs soon.
        
           | dmix wrote:
           | Good documentation is always worth the effort. Markdown
           | explaining your products is gold these days with LLMs.
        
       | nine_k wrote:
       | "We rewrote this code from language _L_ to language _M_ , and the
       | result is better!" No wonder: it was a chance to rectify
       | everything that was tangled or crooked, avoid every known bad
       | decision, and apply newly-invented better approaches.
       | 
       | So this holds even for _L = M_. The speedup is not in the
       | language, but in the rewriting and rethinking.
        
         | MiddleEndian wrote:
         | Now they just need a third party who's never seen the original
         | to rewrite their TypeScript solution in Rust for even more
         | gains.
        
           | nine_k wrote:
           | Indeed! But only after a year or so of using it in
           | production, so that the drawbacks would be discovered.
        
       | spankalee wrote:
       | I was wondering why I hadn't heard of Open UI doing anything with
       | WASM.
       | 
       | This new company chose a very confusing name that has been used
       | by the Open UI W3C Community Group for over 5 years.
       | 
       | https://open-ui.org/
       | 
       | Open UI is the standards group responsible for HTML having
       | popovers, customizable select, invoker commands, and accordions.
       | They're doing great work.
        
       | caderosche wrote:
       | What is the purpose of the Rust WASM parser? Didn't understand
       | that easily from the article. Would love a better explanation.
        
       ___________________________________________________________________
       (page generated 2026-03-20 23:00 UTC)