vue reports exception
:8080/#/:2961 Uncaught TypeError: Cannot read property 'matched' of undefined
reason:
The vue constructor needs to strictly follow the standard;
For example, routers are called routers
import router from './routes.js' const app = new View({ the: '#app', router, render: h => h(App) }) The above is correct; The following is wrong: import rou from './routes.js' const app = new View({ the: '#app', rou, render: h => h(App) })
The route name must be: router
If you want to customize:
import routes from './routes.js' const app = new View({ the: '#app', router: routes, render: h => h(App) })