Skip to content

Trying to use both the react form builder and the factory pattern #7

Answered by sandulat
vondersam asked this question in Q&A
Discussion options

You must be logged in to vote

@vondersam Perhaps it's because the component re-renders when you call setActiveEntityId, causing the builder to be recreated and, consequently, the store as well, since it depends on it. Try creating the builder outside the component or memoizing it.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by vondersam
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants