<template>
  <div class="detail-container">{{ msg }}</div>
</template>

<script>
export default {
  data() {
    return {
      msg: '页面1',
    }
  },
  watch: {
    $route: {
      handler(route) {
        console.log(route)
        this.msg = route.query.name
      },
      deep: true,
      immediate: true,
    },
  },
}
</script>
<style lang="scss" scoped>
.detail-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 30px;
  color: #000;
}
</style>
