安装了路由模块后没有跳转。

解决:

需要做3件事:

1,配置main.js

2,配置index.js

3,在APP.vue里面加入<router-view> (这个一定要记住)

 

<template>
  <div id="app">
    <router-view />
  </div>
</template>

<script>
export default {
  name: 'App'
}
</script>

 

Logo

Vue社区为您提供最前沿的新闻资讯和知识内容

更多推荐