Я хочу использовать vue router в weex, но теперь возникает проблема: «Нет конфигурации компонента для имени: router-view, используйте конфигурацию по умолчанию».Спасибо.
router.js
/*global Vue*/
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
Vue.use(Router)
module.exports = new Router({
routes: [
{
path: '/',
name: 'HelloWorld',
component: HelloWorld
}
]
})
HelloWorld.vue
<template>
<text class="message">Now, let's use Vue.js to build your Weex app.</text>
</template>
index.vue
<template>
<div class="wrapper">
<image :src="logo" class="logo" />
<text class="greeting">The environment is ready!</text>
<router-view/>
</div>
</template>