You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
constApp=regenerator(function*(){console.log('This code snippet is called each time the component Time is updated')console.log('This behavior occurs because of immutagen')const{ loading, data }=yieldprops=><Query{...props}/>;const{ time }=yieldprops=><Time{...props}/>;// If you uncomment this code, there will be two calls of the whole code with each// update of the Time// yield ({ children }) => <div>{children()}</div>return(<divclassName="App">{loading ? (<h1>Loading</h1>) : (<div><h1>{`Hello, ${data.user.name}`}</h1><h2>The time is {time.toLocaleString()}!</h2></div>)}</div>);});
The text was updated successfully, but these errors were encountered:
gtkatakura
changed the title
immutagen execute all generator for any HOC (accumulates all calls)
immutagen execute all generator for any component (accumulates all calls)
Sep 6, 2018
Thanks for
This indeed happens, still need to check if it can indeed be really problematic and/or see if we can change a bit immutagen to not need to call the generator over again
The text was updated successfully, but these errors were encountered: