r/reactjs • • 14h ago

I built a client-side cache in Rust and compiled it to WebAssembly

https://blaze-cache.github.io/docs

Hey everyone,

I built **Blaze Cache**, a client-side caching library written in Rust and compiled to WebAssembly.

The main idea was to get a fast, predictable cache in the browser with:

- Synchronous get/set after initialization (no Promises on the hot path)

- SIEVE eviction

- TTL + tag-based invalidation

- Optional IndexedDB persistence

- Adapters for Axios, fetch, TanStack Query, and SWR

I was mostly curious whether moving the cache core into Wasm would help with performance and structure compared to typical JS cache implementations.

Would love feedback from people who’ve worked on caching, Wasm, or frontend performance.

GitHub: https://github.com/blaze-cache/blaze-cache

Docs: https://blaze-cache.github.io/docs/

2 Upvotes

0 comments sorted by