Hi, could you analyze my code ? I cannot see the errors.
The router-view do not load the Component Login.vue
main.ts
import { createApp } from 'vue'
import App from './App.vue'
import 'bootstrap/dist/css/bootstrap.min.css';
import router from "./router";
createApp(App)
.use(router)
.mount('#app')
index.ts
import {createRouter, createWebHashHistory} from "vue-router";
import Login from '../views/Login.vue'
const routes =[{
path: '/login',
name: 'Login',
component: Login
}]
const router = createRouter({
history: createWebHashHistory(),
routes: routes
})
export default router;
Login.vue
<template>
<h1>Login</h1>
</template>
<script>
export default {
name: "LoginA"
}
</script>
<style scoped>
</style>
App.vue
<template>
<router-view id="login">
</router-view>
</template>
<script>
export default {
name: 'App',
components: {
}
}
</script> ```
I'm still learning, then I'm sorry.