1

So I'm just wondering on how to add # to the URL as you're scrolling down to different sections as in Vue's website itself.

I understand the # depends on the id of of the section. Does it have to do with ScrollBehavior?

Do they have to have 1 thing in common, such as a common class or like in Vue's website, they're all h2 components?

Do I have to change any of the options in the router itself? Been googling about this but can't really find anything that's helping my understanding.

#edit: Just realised not everything's h2 so now I'm more confused.

huhehu
  • 35
  • 3
  • [Possible dupe](https://stackoverflow.com/questions/40382388/how-to-set-url-query-params-in-vue-with-vue-router/40394184) – mplungjan Oct 11 '21 at 06:00
  • Nevermind, found the [answer](https://stackoverflow.com/questions/68345229/how-to-change-the-hash-in-the-url-dynamically-when-i-scroll-over-components-in-v) – huhehu Oct 11 '21 at 09:16

0 Answers0