-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
fix: Ensure gauges not undefined or empty object and gauges fixes #10944
base: develop
Are you sure you want to change the base?
fix: Ensure gauges not undefined or empty object and gauges fixes #10944
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
6 Skipped Deployments
|
|
|
||
return gauges | ||
} | ||
return [] as Gauge[] | ||
throw Error('Failed to fetch gauges') |
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.
to retry if it fails
b672a08
to
15ecaa7
Compare
7f12618
to
99944fb
Compare
1651051
to
ed32bcd
Compare
@chef-ryan you can review it again |
Fixes search query removed when account connect
Fixes discrepancy between search query and list
Fixes undefined or empty gauges causes percent object constructor error
Memoize callbacks to reduce rerenders on client side
PR-Codex overview
This PR focuses on improving the functionality and robustness of the
GaugesVoting
components. Key changes include handling undefined values, enhancing performance withuseCallback
, and refining the sorting and filtering mechanisms.Detailed summary
maxCapPercent
to handle undefined values.useGauges
to ensure valid gauges.SearchInput
withuseCallback
for better performance.FilterFieldInput
to use a callback for change handling.GaugesTable
sorting logic.useCallback
forhandleSort
andhandleOnCollapse
functions.