Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
@mathewparet/vue-recaptcha-invisible
Advanced tools
A Vue.JS component for invisible recaptcha that falls back to native button if recaptcha is disabled in config, making it easy to have different settings for different environments.
A Vue.JS component for invisible recaptcha that falls back to native button if recaptcha is disabled in config, making it easy to have different settings for different environments.
# instal the module
npm install @mathewparet/vue-recaptcha-invisible
import Recaptcha from '@mathewparet/vue-recaptcha-invisible';
Vue.use(Recaptcha, {
enabled: true,
siteKey: '<site key from Google>'
});
recaptcha.config.json
If you do not wish to pass the configuration while initializing the component - i.e, if you wish to register the component as Vue.use(Recaptcha)
then you can define a JSON file of the below format and save it directly under your public
directory. It must have the exact filename recaptcha.config.json
.
{
"siteKey": "<sitekey received from Google>",
"enabled: true
}
For your convinience, a sample recaptcha.config.json
file is placed in your project root (not the public
directory) directory when you run npm install @mathewparet/vue-recaptcha-invisible
. You can copy this file to the public
directory and modify the configuration as needed.
Note - You need to add your<public_dir>/<recaptcha-config-file>.json
to .gitignore
since this configuration should be different for each environment.
If you wish to use a custom file name for the config file, then you will need to pass the same as an option when registering the compoenent, like:
import Recaptcha from '@mathewparet/vue-recaptcha-invisible';
Vue.use(Recaptcha, {
url: '/my-custom-recaptcha-conf-file.json'
})
<recaptcha class-name="btn btn-primary">Submit</recaptcha>
Your <form>
element MUST have an ID
defined
Name | Type | Required | Description |
---|---|---|---|
class-name | String | No | CSS Class name to be applied. |
FAQs
A Vue.JS component for invisible recaptcha that falls back to native button if recaptcha is disabled in config, making it easy to have different settings for different environments.
We found that @mathewparet/vue-recaptcha-invisible demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.