Answer the question
In order to leave comments, you need to log in
How to add only hash to jump address?
For example, the address /page?n=2 is already open and I want to add only #some using either router-link or programmatically via push . In this case, the page itself and the URL parameters can be different. I just need to add the hash to the end. While doing this
let route = Object.assign({}, this.$route, { hash: this.hash });
this.$router.push(route);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question