Skip to content

Instantly share code, notes, and snippets.

@PierBover
Last active November 11, 2018 22:01
Show Gist options
  • Save PierBover/bb62bf09944fb65b38bd240b3eadffab to your computer and use it in GitHub Desktop.
Save PierBover/bb62bf09944fb65b38bd240b3eadffab to your computer and use it in GitHub Desktop.
var store = {
counter: 0,
addOne () {
this.counter ++;
}
};
var componentA = new Vue({
data: {
counter: store.counter
}
});
var componentB = new Vue({
data: {
counter: store.counter
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment