Vue router:TypeError:Cannot read property'$createElement'of undefinedというエラーが発生しました.どうすればいいですか.
465 ワード
このエラーは、ルーティング割り当てテーブルを書くときにcomponentを書くときにsを1つ多く書いて、削除すればいいからです.
エラーコードは次のとおりです.
正しいコードは次のとおりです.
エラーコードは次のとおりです.
const routes =[
{
path:'/home',
components:Home
},
{
path:'/cart',
components:Cart
}
]
正しいコードは次のとおりです.
const routes =[
{
path:'/home',
component:Home
},
{
path:'/cart',
component:Cart
}
]