-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
feat(efb): Fix refresh of atc list issue during flight #5186
Merged
Merged
Changes from 25 commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
c37d88d
display page with the list of ATCs
ZeroKaa b4bb9bd
code simplification
ZeroKaa de71d86
fix sorting issue
ZeroKaa 429bdae
clean console.log
ZeroKaa bc9b0b8
performance improvment
ZeroKaa 87651a6
remove useless css file
ZeroKaa 8d95683
add wrap for text atis
ZeroKaa 7fd37c1
align with new api-client version
ZeroKaa 9ff8d37
Merge branch 'flypados-v2' of https://github.com/flybywiresim/a32nx i…
ZeroKaa eb63dae
merge
ZeroKaa db6ab62
merge
ZeroKaa b7947e3
Revert "merge"
ZeroKaa 6df3834
update api-client package
ZeroKaa ef45e2b
Update ATC.tsx
ZeroKaa d04ed0a
Revert "Update ATC.tsx"
ZeroKaa b3b1159
fix issue on atc list refresh
ZeroKaa 1e3e78e
remove console.log
ZeroKaa c17baa3
add atis controllers in ATC page
ZeroKaa ea223d2
remove console.log
ZeroKaa 234aa34
decrease refresh rate
ZeroKaa 28fe087
Merge branch 'flypados-v2' of https://github.com/flybywiresim/a32nx i…
ZeroKaa fc726c9
fix refresh issue
ZeroKaa 16b2a96
remove double load
ZeroKaa 373e071
increase font-size
ZeroKaa 6967808
fix distance calculation
ZeroKaa e983dbe
use useCallback and useInterval
ZeroKaa c72a812
add atisSource as dependency
ZeroKaa abe3d46
try to repect rules of hook
ZeroKaa File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Why have you added
lastUpdate
as a dependency to this hook? You're not using it.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.
the hook executes everytime lastUpdate change.
I had to use this 'hack' otherwise the "currentLatitude" and "currentLongitude" wasn't updated within the setInterval()
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.
In that case you're hiding the real dependencies currentLatitude and currentLongitude. You could refactor the loadAtc to use useCallback instead and make loadAtc a dependency. Or make currentLatitude and currentLongitude a parameter to loadAtc. The proposed change as-is is hacky and not robust at all.