Castore
Making Event Sourcing easy 😎
Install / Use
/learn @castore-dev/CastoreREADME
💖 Huge thanks to the sponsors who help me maintain this repo:
<p align="center"> <a href="https://www.theodo.fr/"><img src="https://github.com/theodo.png" width="50px" alt="Theodo" title="Theodo"/></a></td> <!-- sponsors --><a href="https://github.com/feathersdev"><img src="https://github.com/feathersdev.png" width="50px" alt="feathers.dev" title="feathers.dev"/></a> <a href="https://github.com/li-jia-nan"><img src="https://github.com/li-jia-nan.png" width="50px" alt="lijianan" title="lijianan"/></a> <a href="https://github.com/RaeesBhatti"><img src="https://github.com/RaeesBhatti.png" width="50px" alt="Raees Iqbal" title="Raees Iqbal"/></a> <a href="https://github.com/lucas-subli"><img src="https://github.com/lucas-subli.png" width="50px" alt="Lucas Saldanha Ferreira" title="Lucas Saldanha Ferreira"/></a> <a href="https://github.com/syntaxfm"><img src="https://github.com/syntaxfm.png" width="50px" alt="Syntax" title="Syntax"/></a> <!-- sponsors --> <a href="https://github.com/sponsors/ThomasAribart"><img src="assets/plus-sign.png" width="50px" alt="Plus sign" title="Your brand here!"/></a> </p>Making Event Sourcing easy 😎
Event Sourcing is a data storage paradigm that saves changes in your application state rather than the state itself.
It is powerful as it enables rewinding to a previous state and exploring audit trails for debugging or business/legal purposes. It also integrates very well with event-driven architectures.
However, it is tricky to implement 😅
After years of using it at Theodo, we have grown to love it, but also experienced first-hand the lack of consensus and tooling around it. That's where Castore comes from!
<p align="center"> Castore is a TypeScript library that <b>makes Event Sourcing easy</b> 😎 </p>
Features
🙈 Stack agnostic: Can be used in any JS context (web apps, containers, lambdas... you name it 🙌)
🕊️ Light-weight: opt-in packages only
🏋️ Type-safety pushed to the limit
📐 Validation library agnostic (Zod, JSON schema...) with support for type inference
😍 On-the-shelf adapters for Redux, DynamoDB, SQS, EventBridge and more
🎯 Test tools included
🔧 Migration & maintenance utils available
🎨 React components to visualize and model your event stores
And much more to come 🙌: Admin, snapshots, read models...
