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

Page re-renders when using the transaction for updates #94

Open
maitrid opened this issue Aug 29, 2017 · 2 comments
Open

Page re-renders when using the transaction for updates #94

maitrid opened this issue Aug 29, 2017 · 2 comments

Comments

@maitrid
Copy link

maitrid commented Aug 29, 2017

In an app using Meteor + React that updates couple of documents after the user submits a form, under normal circumstances, only the relevant component updates, but after implementing tx.start, and tx.commit around the data update calls, the whole page re-renders after form submit. Is there anything that can prevent the whole page re-rendering?

@JackAdams
Copy link
Owner

JackAdams commented Aug 30, 2017

Ah... yes. The transactions package writes to top-level fields on the document:transaction_id (always) and, for soft deletes only, deleted.

I'm guessing you're editing a field in a sub-document, which means that whole re-render doesn't normally need to happen. Is that the case?

@maitrid
Copy link
Author

maitrid commented Aug 30, 2017

Yes, that's exactly what i'm doing. Thanks!

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

No branches or pull requests

2 participants