In main.js generated with vue-cli tool
import Vue from 'vue'
import App from './App'
import router from './router'
Vue.config.productionTip = false
/* eslint-disable no-new */
new Vue({
el: '#app',
router,
template: '<App/>',
components: { App }
})
[template: '<App/>']What does this sentence mean?
Does it mean using the app.vue template? But I haven’t seen such usage in vue!
There are only:
1 template:'#xxx' Get based on id
2 template:'<xx>...<xx>' Use it directly
Is there any related one? What about the documentation? Thanks
https://www.mmxiaowu.com/arti...
I have answered the answer myself!
The second template:'<xx>....<xx>', <App/> --> <App></App> is just a component?
Attachment: import App from './App' The App component is imported from here