Skip to content

Instantly share code, notes, and snippets.

@tradingstratagem
Created July 6, 2018 10:43
Show Gist options
  • Save tradingstratagem/fa6b6af7496867be1b9560e9bc4f487c to your computer and use it in GitHub Desktop.
Save tradingstratagem/fa6b6af7496867be1b9560e9bc4f487c to your computer and use it in GitHub Desktop.
<template>
<div>
<button class="btn btn-success" @click="save" v-promise-btn>Working</button>
<button class="btn btn-success" @click="save()" v-promise-btn>Not working</button>
</div>
</template>
<script>
import Vue from 'vue';
import VuePromiseBtn from 'vue-promise-btn';
import 'vue-promise-btn/dist/vue-promise-btn.css';
Vue.use(VuePromiseBtn);
export default {
methods: {
save() {
return new Promise((resolve, reject) => {
});
}
}
}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment