Skip to content

Instantly share code, notes, and snippets.

@cyrilletuzi
Last active December 9, 2017 11:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cyrilletuzi/79b73d7cc9d7ca12e835d1e2a3a3d6a1 to your computer and use it in GitHub Desktop.
Save cyrilletuzi/79b73d7cc9d7ca12e835d1e2a3a3d6a1 to your computer and use it in GitHub Desktop.
import Vue from 'vue';
import Component from 'vue-class-component';
@Component({
template: '<button @click="onClick">Click!</button>'
})
export default class MyComponent extends Vue {
message = 'Hello!'
onClick () {
console.log(this.message)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment