ASU / asu-unity-stack

ASU Unity Design System
https://unity.web.asu.edu/
Other
13 stars 8 forks source link

fix(app-webdir-ui): fix rendered more hooks than during previous render #1177

Closed mlsamuelson closed 1 year ago

mlsamuelson commented 1 year ago

@davidornelas11 This addresses an error I was seeing in Storybook where if you selected the Search Page story and it rendered, then you select a different story, and then try to go back to the Search Page, you get the error "Rendered more hooks than during previous render".

A search on that error turned up this issue, and the fix in this comment resolved the issue.

This PR implements that fix. Can you verify?

mlsamuelson commented 1 year ago

Turns out, that's happening before the SCHWEB-1089 PR, but we can fix it here.

scott-williams-az commented 1 year ago

Awesome! I noticed that error every now and then, but was not able to track it down.

LGTM