vue-recaptcha-v3
Advanced tools
Comparing version 1.5.0 to 1.6.1
"use strict"; | ||
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } | ||
return new (P || (P = Promise))(function (resolve, reject) { | ||
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } | ||
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } | ||
function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); } | ||
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } | ||
step((generator = generator.apply(thisArg, _arguments || [])).next()); | ||
@@ -40,2 +41,3 @@ }); | ||
function VueReCaptcha(Vue, options) { | ||
var _this = this; | ||
var plugin = new ReCaptchaVuePlugin(); | ||
@@ -45,14 +47,18 @@ var recaptchaLoaded = false; | ||
Vue.prototype.$recaptchaLoaded = function () { return new Promise(function (resolve, reject) { | ||
if (recaptchaLoaded === true) | ||
if (recaptchaLoaded === true) { | ||
resolve(true); | ||
else | ||
} | ||
else { | ||
loadedWaiters.push(resolve); | ||
} | ||
}); }; | ||
plugin.initializeReCaptcha(options).then(function (wrapper) { | ||
recaptchaLoaded = true; | ||
Vue.prototype.$recaptcha = function (action) { | ||
return wrapper.execute(action); | ||
}; | ||
Vue.prototype.$recaptcha = function (action) { return __awaiter(_this, void 0, void 0, function () { | ||
return __generator(this, function (_a) { | ||
return [2, wrapper.execute(action)]; | ||
}); | ||
}); }; | ||
loadedWaiters.forEach(function (v) { return v(true); }); | ||
}); | ||
}).catch(console.error); | ||
} | ||
@@ -66,6 +72,3 @@ exports.VueReCaptcha = VueReCaptcha; | ||
return __generator(this, function (_a) { | ||
switch (_a.label) { | ||
case 0: return [4, recaptcha_v3_1.load(options.siteKey, options.loaderOptions)]; | ||
case 1: return [2, _a.sent()]; | ||
} | ||
return [2, recaptcha_v3_1.load(options.siteKey, options.loaderOptions)]; | ||
}); | ||
@@ -72,0 +75,0 @@ }); |
{ | ||
"name": "vue-recaptcha-v3", | ||
"version": "1.5.0", | ||
"version": "1.6.1", | ||
"keywords": [ | ||
@@ -29,6 +29,14 @@ "captcha", | ||
"build": "tsc", | ||
"lint": "eslint \"src/**/*.ts\" \"demo/**/*.ts\"", | ||
"demo:webpack:server": "webpack-dev-server --config demo/webpack.config.js --progress --public --host 0.0.0.0" | ||
}, | ||
"dependencies": { | ||
"recaptcha-v3": "^1.5.0" | ||
"@typescript-eslint/eslint-plugin": "2", | ||
"eslint": "6", | ||
"eslint-config-standard-with-typescript": "^9.0.0", | ||
"eslint-plugin-import": "2", | ||
"eslint-plugin-node": "9", | ||
"eslint-plugin-promise": "4", | ||
"eslint-plugin-standard": "4", | ||
"recaptcha-v3": "^1.6.1" | ||
}, | ||
@@ -38,13 +46,12 @@ "devDependencies": { | ||
"html-webpack-plugin": "^3.2.0", | ||
"ts-loader": "^5.3.0", | ||
"tslint": "^5.11.0", | ||
"typescript": "^3.1.6", | ||
"vue": "^2.5.17", | ||
"webpack": "^4.25.1", | ||
"webpack-cli": "^3.1.2", | ||
"webpack-dev-server": "^3.1.10" | ||
"ts-loader": "^6.1.2", | ||
"typescript": "^3.6.3", | ||
"vue": "^2.6.10", | ||
"webpack": "^4.41.0", | ||
"webpack-cli": "^3.3.9", | ||
"webpack-dev-server": "^3.8.1" | ||
}, | ||
"peerDependencies": { | ||
"vue": "^2.5.17" | ||
"vue": "^2.6.10" | ||
} | ||
} |
@@ -7,15 +7,15 @@ # Vue reCAPTCHA-v3 | ||
## Install | ||
With NPM: | ||
```bash | ||
$ npm install vue-recaptcha-v3 | ||
``` | ||
## Install | ||
With NPM: | ||
```bash | ||
$ npm install vue-recaptcha-v3 | ||
``` | ||
With Yarn: | ||
```bash | ||
$ yarn add vue-recaptcha-v3 | ||
``` | ||
With Yarn: | ||
```bash | ||
$ yarn add vue-recaptcha-v3 | ||
``` | ||
## Prerequisites | ||
To use this package you only need a valid site key for your domain, which you can easily get [here](https://www.google.com/recaptcha). | ||
## Prerequisites | ||
To use this package you only need a valid site key for your domain, which you can easily get [here](https://www.google.com/recaptcha). | ||
@@ -22,0 +22,0 @@ ## Usage |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19090
8
91
9
+ Addedeslint@6
+ Addedeslint-plugin-import@2
+ Addedeslint-plugin-node@9
+ Addedeslint-plugin-promise@4
+ Addedeslint-plugin-standard@4
+ Added@babel/code-frame@7.26.2(transitive)
+ Added@rtsao/scc@1.1.0(transitive)
+ Added@types/eslint-visitor-keys@1.0.0(transitive)
+ Added@types/json-schema@7.0.15(transitive)
+ Added@types/json5@0.0.29(transitive)
+ Added@typescript-eslint/eslint-plugin@2.34.0(transitive)
+ Added@typescript-eslint/experimental-utils@2.34.0(transitive)
+ Added@typescript-eslint/parser@2.34.0(transitive)
+ Added@typescript-eslint/typescript-estree@2.34.0(transitive)
+ Addedacorn@7.4.1(transitive)
+ Addedacorn-jsx@5.3.2(transitive)
+ Addedajv@6.12.6(transitive)
+ Addedansi-escapes@4.3.2(transitive)
+ Addedansi-regex@4.1.15.0.1(transitive)
+ Addedansi-styles@3.2.14.3.0(transitive)
+ Addedargparse@1.0.10(transitive)
+ Addedarray-buffer-byte-length@1.0.1(transitive)
+ Addedarray-includes@3.1.8(transitive)
+ Addedarray.prototype.findlastindex@1.2.5(transitive)
+ Addedarray.prototype.flat@1.3.2(transitive)
+ Addedarray.prototype.flatmap@1.3.2(transitive)
+ Addedarraybuffer.prototype.slice@1.0.3(transitive)
+ Addedastral-regex@1.0.0(transitive)
+ Addedavailable-typed-arrays@1.0.7(transitive)
+ Addedbalanced-match@1.0.2(transitive)
+ Addedbrace-expansion@1.1.11(transitive)
+ Addedcall-bind@1.0.7(transitive)
+ Addedcallsites@3.1.0(transitive)
+ Addedchalk@2.4.24.1.2(transitive)
+ Addedchardet@0.7.0(transitive)
+ Addedcli-cursor@3.1.0(transitive)
+ Addedcli-width@3.0.0(transitive)
+ Addedcolor-convert@1.9.32.0.1(transitive)
+ Addedcolor-name@1.1.31.1.4(transitive)
+ Addedconcat-map@0.0.1(transitive)
+ Addedcross-spawn@6.0.5(transitive)
+ Addeddata-view-buffer@1.0.1(transitive)
+ Addeddata-view-byte-length@1.0.1(transitive)
+ Addeddata-view-byte-offset@1.0.0(transitive)
+ Addeddebug@3.2.74.3.7(transitive)
+ Addeddeep-is@0.1.4(transitive)
+ Addeddefine-data-property@1.1.4(transitive)
+ Addeddefine-properties@1.2.1(transitive)
+ Addeddoctrine@2.1.03.0.0(transitive)
+ Addedemoji-regex@7.0.38.0.0(transitive)
+ Addedes-abstract@1.23.3(transitive)
+ Addedes-define-property@1.0.0(transitive)
+ Addedes-errors@1.3.0(transitive)
+ Addedes-object-atoms@1.0.0(transitive)
+ Addedes-set-tostringtag@2.0.3(transitive)
+ Addedes-shim-unscopables@1.0.2(transitive)
+ Addedes-to-primitive@1.2.1(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedeslint@6.8.0(transitive)
+ Addedeslint-config-standard@14.1.1(transitive)
+ Addedeslint-config-standard-with-typescript@9.0.0(transitive)
+ Addedeslint-import-resolver-node@0.3.9(transitive)
+ Addedeslint-module-utils@2.12.0(transitive)
+ Addedeslint-plugin-es@1.4.1(transitive)
+ Addedeslint-plugin-import@2.31.0(transitive)
+ Addedeslint-plugin-node@9.2.0(transitive)
+ Addedeslint-plugin-promise@4.3.1(transitive)
+ Addedeslint-plugin-standard@4.1.0(transitive)
+ Addedeslint-scope@5.1.1(transitive)
+ Addedeslint-utils@1.4.32.1.0(transitive)
+ Addedeslint-visitor-keys@1.3.0(transitive)
+ Addedespree@6.2.1(transitive)
+ Addedesprima@4.0.1(transitive)
+ Addedesquery@1.6.0(transitive)
+ Addedesrecurse@4.3.0(transitive)
+ Addedestraverse@4.3.05.3.0(transitive)
+ Addedesutils@2.0.3(transitive)
+ Addedexternal-editor@3.1.0(transitive)
+ Addedfast-deep-equal@3.1.3(transitive)
+ Addedfast-json-stable-stringify@2.1.0(transitive)
+ Addedfast-levenshtein@2.0.6(transitive)
+ Addedfigures@3.2.0(transitive)
+ Addedfile-entry-cache@5.0.1(transitive)
+ Addedflat-cache@2.0.1(transitive)
+ Addedflatted@2.0.2(transitive)
+ Addedfor-each@0.3.3(transitive)
+ Addedfs.realpath@1.0.0(transitive)
+ Addedfunction-bind@1.1.2(transitive)
+ Addedfunction.prototype.name@1.1.6(transitive)
+ Addedfunctional-red-black-tree@1.0.1(transitive)
+ Addedfunctions-have-names@1.2.3(transitive)
+ Addedget-intrinsic@1.2.4(transitive)
+ Addedget-symbol-description@1.0.2(transitive)
+ Addedglob@7.2.3(transitive)
+ Addedglob-parent@5.1.2(transitive)
+ Addedglobals@12.4.0(transitive)
+ Addedglobalthis@1.0.4(transitive)
+ Addedgopd@1.0.1(transitive)
+ Addedhas-bigints@1.0.2(transitive)
+ Addedhas-flag@3.0.04.0.0(transitive)
+ Addedhas-property-descriptors@1.0.2(transitive)
+ Addedhas-proto@1.0.3(transitive)
+ Addedhas-symbols@1.0.3(transitive)
+ Addedhas-tostringtag@1.0.2(transitive)
+ Addedhasown@2.0.2(transitive)
+ Addediconv-lite@0.4.24(transitive)
+ Addedignore@4.0.65.3.2(transitive)
+ Addedimport-fresh@3.3.0(transitive)
+ Addedimurmurhash@0.1.4(transitive)
+ Addedinflight@1.0.6(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedinquirer@7.3.3(transitive)
+ Addedinternal-slot@1.0.7(transitive)
+ Addedis-array-buffer@3.0.4(transitive)
+ Addedis-bigint@1.0.4(transitive)
+ Addedis-boolean-object@1.1.2(transitive)
+ Addedis-callable@1.2.7(transitive)
+ Addedis-core-module@2.15.1(transitive)
+ Addedis-data-view@1.0.1(transitive)
+ Addedis-date-object@1.0.5(transitive)
+ Addedis-extglob@2.1.1(transitive)
+ Addedis-fullwidth-code-point@2.0.03.0.0(transitive)
+ Addedis-glob@4.0.3(transitive)
+ Addedis-negative-zero@2.0.3(transitive)
+ Addedis-number-object@1.0.7(transitive)
+ Addedis-regex@1.1.4(transitive)
+ Addedis-shared-array-buffer@1.0.3(transitive)
+ Addedis-string@1.0.7(transitive)
+ Addedis-symbol@1.0.4(transitive)
+ Addedis-typed-array@1.1.13(transitive)
+ Addedis-weakref@1.0.2(transitive)
+ Addedisarray@2.0.5(transitive)
+ Addedisexe@2.0.0(transitive)
+ Addedjs-tokens@4.0.0(transitive)
+ Addedjs-yaml@3.14.1(transitive)
+ Addedjson-schema-traverse@0.4.1(transitive)
+ Addedjson-stable-stringify-without-jsonify@1.0.1(transitive)
+ Addedjson5@1.0.2(transitive)
+ Addedlevn@0.3.0(transitive)
+ Addedlodash@4.17.21(transitive)
+ Addedmimic-fn@2.1.0(transitive)
+ Addedminimatch@3.1.2(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addedmkdirp@0.5.6(transitive)
+ Addedms@2.1.3(transitive)
+ Addedmute-stream@0.0.8(transitive)
+ Addednatural-compare@1.4.0(transitive)
+ Addednice-try@1.0.5(transitive)
+ Addedobject-inspect@1.13.2(transitive)
+ Addedobject-keys@1.1.1(transitive)
+ Addedobject.assign@4.1.5(transitive)
+ Addedobject.fromentries@2.0.8(transitive)
+ Addedobject.groupby@1.0.3(transitive)
+ Addedobject.values@1.2.0(transitive)
+ Addedonce@1.4.0(transitive)
+ Addedonetime@5.1.2(transitive)
+ Addedoptionator@0.8.3(transitive)
+ Addedos-tmpdir@1.0.2(transitive)
+ Addedparent-module@1.0.1(transitive)
+ Addedpath-is-absolute@1.0.1(transitive)
+ Addedpath-key@2.0.1(transitive)
+ Addedpath-parse@1.0.7(transitive)
+ Addedpossible-typed-array-names@1.0.0(transitive)
+ Addedpostcss@8.4.47(transitive)
+ Addedprelude-ls@1.1.2(transitive)
+ Addedprogress@2.0.3(transitive)
+ Addedpunycode@2.3.1(transitive)
+ Addedregexp.prototype.flags@1.5.3(transitive)
+ Addedregexpp@2.0.13.2.0(transitive)
+ Addedresolve@1.22.8(transitive)
+ Addedresolve-from@4.0.0(transitive)
+ Addedrestore-cursor@3.1.0(transitive)
+ Addedrimraf@2.6.3(transitive)
+ Addedrun-async@2.4.1(transitive)
+ Addedrxjs@6.6.7(transitive)
+ Addedsafe-array-concat@1.1.2(transitive)
+ Addedsafe-regex-test@1.0.3(transitive)
+ Addedsafer-buffer@2.1.2(transitive)
+ Addedsemver@5.7.26.3.17.6.3(transitive)
+ Addedset-function-length@1.2.2(transitive)
+ Addedset-function-name@2.0.2(transitive)
+ Addedshebang-command@1.2.0(transitive)
+ Addedshebang-regex@1.0.0(transitive)
+ Addedside-channel@1.0.6(transitive)
+ Addedsignal-exit@3.0.7(transitive)
+ Addedslice-ansi@2.1.0(transitive)
+ Addedsprintf-js@1.0.3(transitive)
+ Addedstring-width@3.1.04.2.3(transitive)
+ Addedstring.prototype.trim@1.2.9(transitive)
+ Addedstring.prototype.trimend@1.0.8(transitive)
+ Addedstring.prototype.trimstart@1.0.8(transitive)
+ Addedstrip-ansi@5.2.06.0.1(transitive)
+ Addedstrip-bom@3.0.0(transitive)
+ Addedstrip-json-comments@3.1.1(transitive)
+ Addedsupports-color@5.5.07.2.0(transitive)
+ Addedsupports-preserve-symlinks-flag@1.0.0(transitive)
+ Addedtable@5.4.6(transitive)
+ Addedtext-table@0.2.0(transitive)
+ Addedthrough@2.3.8(transitive)
+ Addedtmp@0.0.33(transitive)
+ Addedtsconfig-paths@3.15.0(transitive)
+ Addedtslib@1.14.1(transitive)
+ Addedtsutils@3.21.0(transitive)
+ Addedtype-check@0.3.2(transitive)
+ Addedtype-fest@0.21.30.8.1(transitive)
+ Addedtyped-array-buffer@1.0.2(transitive)
+ Addedtyped-array-byte-length@1.0.1(transitive)
+ Addedtyped-array-byte-offset@1.0.2(transitive)
+ Addedtyped-array-length@1.0.6(transitive)
+ Addedtypescript@5.6.3(transitive)
+ Addedunbox-primitive@1.0.2(transitive)
+ Addeduri-js@4.4.1(transitive)
+ Addedv8-compile-cache@2.4.0(transitive)
+ Addedwhich@1.3.1(transitive)
+ Addedwhich-boxed-primitive@1.0.2(transitive)
+ Addedwhich-typed-array@1.1.15(transitive)
+ Addedword-wrap@1.2.5(transitive)
+ Addedwrappy@1.0.2(transitive)
+ Addedwrite@1.0.3(transitive)
- Removedpostcss@8.4.49(transitive)
Updatedrecaptcha-v3@^1.6.1