Skip to content

Commit

Permalink
minor
Browse files Browse the repository at this point in the history
  • Loading branch information
kaf-lamed-beyt authored Nov 26, 2023
1 parent ac8fe6a commit 7002d13
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ state-aware tab components in react built with Next.js router.

This started off from working with the Tab component in ChakraUI. Although, there's a "managing active tab state" section in their docs and that may suffice for some of your use-cases.

With react-tabs, you might not need to write the logic to manage just the active state of your tab items or use state management library. The state of the tab component is preserved in the browser URL when you switch between routes.
With react-tabs, you might not need to write the logic to manage just the active state of your tab items or use a state management library. The state of the tab component is preserved in the browser URL when you switch between routes.

Say, for example, there are four `tabItems`, you procced to select the second tab item and navigate to another route or you refresh the current page, React re-renders the component and the state is lost, hence the active component goes back to being the first `tabItem`.

Expand Down

0 comments on commit 7002d13

Please sign in to comment.