stable-structures icon indicating copy to clipboard operation
stable-structures copied to clipboard

missing/outdated crate documentation

Open letmejustputthishere opened this issue 10 months ago • 3 comments

  • [x] romans blog, the crate docs and the examples are not in sync. this is mainly around the fact that StableBTreeMap does not require devs to specify a bound anymore
  • [ ] there aren't examples for how to use the library except for StableMinHeap and StableBTreeMap
  • [ ] StableVec requiresBound::Bound , which is not documented and compiles, but throws runtime errors
  • [ ] more docs and examples around schema upgrades and what pitfalls to avoid

letmejustputthishere avatar Feb 25 '25 15:02 letmejustputthishere

[ ] Mention that MemoryManager should be instantiated only once unless you know that you are doing (TM)

michael-weigelt avatar Feb 25 '25 15:02 michael-weigelt

in general, i think both the DX and docs could be improved. this is a crate that is heavily used, but not very accessible IMO.

IIRC @keplervital has some tooling that would improve DX, like a storable macro and wrappers around the StableBTreeMap that provide indices and other convenient functionalities

letmejustputthishere avatar Feb 25 '25 15:02 letmejustputthishere

tackled in https://github.com/dfinity/stable-structures/pull/284

letmejustputthishere avatar Apr 22 '25 09:04 letmejustputthishere