JSFiddle - React, Tailwind, and code Playground
by skirtle
HTML
<div id="app"></div>
JavaScript
new Vue({
render (h) {
console.log('render')
return h('button', {
on: {
click: () => {
this.count++
}
}
}, [`Update: ${this.count}`])
},
data () {
return {
count: 0
}
},
beforeMount () {
console.log('beforeMount')
},
mounted () {
console.log('mounted')
},
beforeUpdate () {
console.log('beforeUpdate')
},
updated () {
console.log('updated')
},
watch: {
count () {
console.log('watch')
}
}
}).$mount('#app')