Skip to content

How do I get rid of UI Flicker? #2100

Answered by connorlanigan
rexwreyes asked this question in Q&A
Discussion options

You must be logged in to vote

It looks like your application might be performing a full page load when you navigate to a new page, instead of performing a client-side navigation only. You can specify handlers on the TopNavigation component that are called when a link in the TopNavigation is clicked:

  • the object in the identity prop takes an onFollow field
  • the objects in the utilities prop take an onFollow (for buttons) or onItemFollow (for menu dropdowns) field

In those handlers, you can then cancel the browser's full-page navigation and perform a client-side navigation using your framework's routing functionality. In NextJS, you should be able to use the useRouter hook (see the NextJS documentation) for that.
Someth…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by connorlanigan
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants