@appsbd/vue3-recaptcha
v1.0.3
Published
This is plugin is for table grid
Downloads
97
Maintainers
Readme
Vue3 reCaptcha v3
Install :
npm i @appsbd/vue3-recaptcha
Use
<recaptcha ref="mrecaptcha" :site-key="your_site_key" />
Get Token
var token = await this.$refs.mrecaptcha.getToken();
Full Example :
<template>
<div id="app">
<recaptcha ref="mrecaptcha"
:site-key="site_key"
:hide-badge="hide_badge"/>
<button type="button"
@click=" this.hide_badge = !this.hide_badge;">Hide badge</button>
<button type="button"
@click="submit">Submit</button>
</div>
</template>
<script>
import { defineComponent } from 'vue';
import recaptcha from '@appsbd/vue3-recaptcha';
export default defineComponent({
name: 'App',
components: {
recaptcha
},
data() {
return {
site_key:'your_site_key_here',
hide_badge:false
}
},
methods: {
async submit() {
var token = await this.$refs.mrecaptcha.getToken();
console.log(token);
}
}
});
</script>
Any Issue or Suggestion, please contact :
[email protected]