I have integrated the Angular Google Recaptcha directive into my application from https://github.com/VividCortex/angular-recaptcha. However, upon running my application, I encountered an error stating that I am using my public key instead of my private key. I attempted to enclose the key in single quotes within double quotes, but faced the same issue.
The specific error message is: error: [$parse:syntax] Syntax Error: Token '6LflNBo000000000' is an unexpected token at column 2 of the expression [6LflNBo00000000000-0000000000000] starting at [6LflNBo00000000-0000000000000000].
Here are the relevant sections from the code:
<script src='https://www.google.com/recaptcha/api.js'></script>
Footer:
<script src="https://www.google.com/recaptcha/api.js?onload=vcRecaptchaApiLoaded&render=explicit" async defer ></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular-recaptcha/3.0.3/angular-recaptcha.min.js"></script>
AngularJS:
angular.module('main', ['ngSanitize', 'ngRoute', 'cb.x2js', 'ui.bootstrap', 'vcRecaptcha']).....
HTML Markup:
<div
vc-recaptcha
key="6LflNBo000000000-000000000000000"
ng-model="user.captcha" // --> used for validation>
</div>