Skip to content
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: update Tabs when clicking link on same page #982

Merged
merged 1 commit into from
Jan 10, 2024

Conversation

sunnyzanchi
Copy link
Contributor

the useEffect in Tabs.js was only running on page load, so linking to a tab on the same page wouldn't update the Tabs. rerunning the effect when location.hash changes fixes this

the `useEffect` in Tabs.js was only running on page load,
so linking to a tab on the same page wouldn't update the Tabs.
rerunning the effect when `location.hash` changes fixes this
@sunnyzanchi sunnyzanchi requested review from a team, LizBaker and tabathadelane and removed request for a team January 10, 2024 18:03
Copy link

gatsby-cloud bot commented Jan 10, 2024

✅ gatsby-theme-newrelic-develop deploy preview ready

@sunnyzanchi sunnyzanchi merged commit 7a0ded0 into develop Jan 10, 2024
6 checks passed
@sunnyzanchi sunnyzanchi deleted the sunny/tabs-update-on-nav branch January 10, 2024 18:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants