Ask for help, Vue demo set up Router can't render router-view

Don"t say too much, just go to the code, this is my Vue-router demo code, open the runtime router-view is not rendered, see who can find out what the problem is.
this is the directory of the file

clipboard.png

index.html

clipboard.png
main.js

clipboard.png

App.vue

clipboard.png

index.js,router

clipboard.png

home.vue

clipboard.png

finally, who knows what the problem is, can tell me what is wrong, we learn from each other, thank you very much!

Feb.21,2022

add the ID-sharpapp;
2.path of the DOM element to the

1.new Vue instance with a slash, as follows

{
    path: '/add-address',
    name: 'AddAddressPage',
    component: AddAddressPage,
},

insert / before path


explain the answer on the first floor:

{ path:"/home",component:home }

and so on.


see your answers, feel very good, the problem has been solved, but my solution is to modify < router-link > and path need to add a slash, and also to re-build the environment, feel that vue cli3.0 is a bit of a pit

Menu