Skip to content

Commit

Permalink
fix: Get only the skiplink anchor hash (vuejs#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
ktquez committed Dec 29, 2021
1 parent 255005f commit c9ad3ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vitepress/components/VPSkipLink.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ watch(
const focusOnTargetAnchor = ({ target }: Event) => {
const el = document.querySelector(
(target as HTMLAnchorElement).href!
(target as HTMLAnchorElement).hash!
) as HTMLAnchorElement
if (el) {
Expand Down

0 comments on commit c9ad3ae

Please sign in to comment.