author.vue
351 Bytes
<template>
<Author ref="author"></Author>
</template>
<script>
import Author from './components/author';
export default {
name: 'author',
activated() {
this.$refs.author.init(this.$route.params);
},
beforeRouteUpdate(to, from, next) {
this.$refs.author.init(to.params);
next();
},
components: {
Author
}
};
</script>