<template>
  <div style="width: 100%">
    这是首页 <button @click="next">去下一页</button> <br />
    用户名：<input v-model="user1" type="text" name="user1" /><br />
    账号：<input v-model="user2" type="text" name="user2" /><br />
    密码： <input v-model="user3" type="password" name="user3" />
  </div>
</template>

<script>
export default {
  name: "PageIndex",
  data() {
    return {
      user: "",
      user2: "",
      user3: "",
    }
 },
  methods: {
    next() {
     
      this.$router.push({
        path: "user",
        query: {
          // 传入参数
          canshu1: this.user1,
          canshu2: this.user2,
          canshu3: this.user3,
          // 自定义传入参数
          // canshu4: 123
        },
      });
    } 
  }
}
</script>

<style scoped>
</style>