How to do it...

You will build a page for a plumber club. The page will look like this:

Whenever we write a name inside the name textbox, it will be written in the greeting exactly like the v-model directive.

For this recipe, we are starting from the end instead of the beginning because usually when you have to resort to the render function, you have a pretty clear idea of what you are trying to get.

In the HTML side of our app, let's start with an empty tag:

<div id="app"></div>

In the JavaScript, write an empty <div> element in the render function:

new Vue({  el: '#app',  render: h => h('div')})

The first thing we'll put inside is the ...

Get Vue.js 2 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.