Full code: https://github.com/kenpeter/test_vue_template
git clone https://github.com/kenpeter/test_vue_template
install: yarn install
run: yarn dev
visit localhost:8080
and see nothing
Full code: https://github.com/kenpeter/test_vue_template
git clone https://github.com/kenpeter/test_vue_template
install: yarn install
run: yarn dev
visit localhost:8080
and see nothing
Because you didn't render anything in your root component.
In your index.html
, render the app
component:
<div id="app">
<app></app>
</div>
There are several ways to do this. If you don't want to touch your index.html
, you can also modify the main.js
. All of the code below should work:
new Vue({
el: '#app',
render: h => h(App),
components: {
App
}
})
or
new Vue({
el: '#app',
template: '<App/>',
components: {
App
}
})