Skip to content

Conversation

@barak007
Copy link

@barak007 barak007 commented Sep 22, 2025

  • Added new package @dazl/state.
  • Implemented BaseStore class with state management capabilities, including actions, subscriptions, and batching.
  • Introduced react-hook for integrating BaseStore with React components.
  • Added react-router integration for creating global stores within React Router.

There are 4 open questions

  1. What should we do with the errors? - currently we throw which and revert state not sure we should do something else
  2. What should we do with side effects? - revert, cancel reapply
  3. What about the Bridge to Dazl?
  4. Who to connect History as Plugin? Done - need self review

- Added package.json for @dazl/state with basic metadata and scripts.
- Implemented BaseStore class with state management capabilities, including actions, subscriptions, and batching.
- Created TestStore class for testing purposes, featuring actions like increment, setText, and nested actions.
- Developed unit tests for BaseStore to ensure functionality and reliability.
- Introduced react-hook for integrating BaseStore with React components.
- Added react-router integration for creating global stores within React Router.
- Configured TypeScript settings for the state package.
- Added History class to manage state changes with undo/redo functionality.
- Introduced HistoryEntry interface to represent individual history entries.
- Enhanced BaseStore with restoreFromHistory method to facilitate state restoration.
- Created TestStore for testing state management features.
- Developed playground.html for interactive testing of state management and history features.
- Implemented comprehensive unit tests for History class covering various scenarios including undo/redo, branching, and error handling.
]
}
],
"skipLibCheck": true
Copy link
Contributor

@AviVahl AviVahl Oct 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want to have type checks on all ts files, including .d.ts ones.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants