-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: decompose OrderRow component #5335
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
apps/cowswap-frontend/src/modules/ordersTable/pure/CurrencyAmountItem/index.tsx
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
{...props} | ||
/> | ||
) | ||
|
||
const renderLimitPrice = () => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we remove renderWarningEstimatedPrice too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed the commits, it looks great to me.
Summary
Please, review this PR commit by commit.
OrderRow
to containers since this component became complex enough and it doesn't make sense to pass all the required data through props. It's just a relocation, no real changes right now, I will do it in the next PRs.OrderRow
showIcon
prop fromWarningTooltip
The goal of the refactoring is to get rid of excessive rerenders.
Main cause of them is a lot of count of function that renders separate UI, like here.
To Test
No need to test now, since this is not final refactoring PR.