[Vuejs]-Error: render function or template not defined in component: anonymous

0👍

Try providing a template property or a render function in your Vue instance.

new Vue({ template: `<div>Hello there!</div>` })

The following lines below only means that you want to use your own page template for the renderer where your app’s markup will be injected later.

const renderer = vssr.createRenderer({
    template: require('fs').readFileSync('./templates/index.html', 'utf-8')
});

Leave a comment