export default {
data: () => ({
comments: [],
}),
methods: {
loadComments() {
this.comments = axios.get('...').then(response => response.data)
},
scrollToComment() {}
},
async mounted() {
await this.loadComments();
const commentId = this.$router.query.comment
// scrollToComment - ваша функция, которая скроллит до коммента
this.$nextTick(this.scrollToComment(commentId))
}
}