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
Currently, we re-setup the wallet whenever the wallet modal is opened. This action resets the wallet, which involves resetting its balances and re-fetching them. As a result, the WithdrawDAIPanel, whose current state and title is displayed via a computed property that depends on the amount of DAI in VAT, collapses and expands whenever the wallet modal is opened (see Assets). Additionally, whenever the withdraw button is clicked, the animation due to AnimatedNumber is rerun (see Assets). I guess this has to do with the fact that BaseButton treats the loading and non-loading cases as two separate templates.
Goal
Optimize wallet setup and balances fetching.
Context
Currently, we re-setup the wallet whenever the wallet modal is opened. This action resets the wallet, which involves resetting its balances and re-fetching them. As a result, the
WithdrawDAIPanel
, whose current state and title is displayed via a computed property that depends on the amount of DAI in VAT, collapses and expands whenever the wallet modal is opened (see Assets). Additionally, whenever the withdraw button is clicked, the animation due toAnimatedNumber
is rerun (see Assets). I guess this has to do with the fact thatBaseButton
treats the loading and non-loading cases as two separate templates.Assets
perf.mp4
Tasks
store
logic that allows wallet balances to persist when re-fetching isn't necessary.BaseButton
so that it switches between the loading and non-loading state in a single template (if this is why the animation is rerun)The text was updated successfully, but these errors were encountered: