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
Add simple Component that returns undefined in usePlasmicQueryData:
exportconstQueryComponent=({children}: {children: ReactNode})=>{console.log("I'm being rendered")constdata=usePlasmicQueryData("query",()=>{// comment this line and the infinite loop goes awayreturnundefined;return{data: "test",}})console.log("Data: ",data)return<DataProviderdata={data}>{children}</DataProvider>}
Simple reproduction:
I also created a reproduction repo: https://github.com/lucasmerlin/plasmic-loop-debug
Expected behaviour
I would expect the usePlasmicQueryData just to return undefined or to throw an error maybe, but no infinite loop.
The text was updated successfully, but these errors were encountered: