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
The useIsScreenReaderEnabled function in hooks.tsx was updated for a needed adjustment on short notice for the Nav project going out in a manner that ensured consistent behavior for preexisting functionality with potentially unnecessary safeguards on ticket #5047. This issue is to check if the potentially unnecessary safeguards can be removed (it is believed they can) without breaking existing use cases.
The specific aims of this code upkeep are:
Check if the two other hooks that leverage useIsScreenReaderEnabled still work as desired when withListener argument is removed and the function is always adding a listener (will reflect the update immediately when screen reader status is changed on/off, instead of only checking once at render time)
Investigate if the isMounted variable needs to exist anymore either after always using the listener, remove if it doesn't
Update the documentation (documentation/docs/Engineering/FrontEnd/CustomHooks/useIsScreenReaderEnabled.mdx) to match after-this-ticket functionality and document the additional example variety added with spike/5010-roettger-ScreenReaderResponsiveTransitionHeader #5047 and any others in the interim
Why Should We Prioritize?
Would greatly streamline this hook's functionality to be clear, concise, and efficient; potentially function better than it does now for existing use cases; and should be a fairly small lift.
The text was updated successfully, but these errors were encountered:
Proposed Change
The useIsScreenReaderEnabled function in hooks.tsx was updated for a needed adjustment on short notice for the Nav project going out in a manner that ensured consistent behavior for preexisting functionality with potentially unnecessary safeguards on ticket #5047. This issue is to check if the potentially unnecessary safeguards can be removed (it is believed they can) without breaking existing use cases.
The specific aims of this code upkeep are:
Why Should We Prioritize?
Would greatly streamline this hook's functionality to be clear, concise, and efficient; potentially function better than it does now for existing use cases; and should be a fairly small lift.
The text was updated successfully, but these errors were encountered: