怎么改写成vue3语法,老师?
Vue3.0.0
//main.js import {createApp} from 'vue' import App from './App.vue' import router from './router' import store from './store' import ElementUI from 'element-plus' import 'element-plus/lib/theme-chalk/index.css' import './static/css/base.less' import './globalComponents' const app = createApp(App) app.use(store) app.use(router) app.use(ElementUI) app.mount('#app')
globalComponent/index.js
import { createApp } from 'vue' import App from '../App.vue' import AccountLogin from "../components/accountLogin/AccountLogin" createApp(App).component('AccountLogin', AccountLogin)
在App.vue中调用组件
<div> <accout-login></accout-login> </div>
无效,结果显示不了组件,不知道哪出问题,老师vue3该怎么改写