Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generic Store Functions Enable Yjs #53

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Conversation

jbolda
Copy link
Collaborator

@jbolda jbolda commented Dec 19, 2024

WIP

Copy link
Owner

@neurosnap neurosnap left a comment

Choose a reason for hiding this comment

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

Overall looks good to me, but this means that yjs is the "backend" for our store and there's no ability to overlap. As long as we are fine with that idea I'm good as well.

@@ -113,6 +133,27 @@ export function createStore<S extends AnyState>({
yield* next();
}

if (determineNextState?.setup) determineNextState.setup();

function* updateMdw(ctx: UpdaterCtx<S>, next: Next) {
Copy link
Owner

Choose a reason for hiding this comment

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

This could be a mdw that users always provide instead of forcing it to be included in the store. In that case this would reduce the default store functionality, just a thought.

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.

2 participants