Skip to content

RecaptchaInstance

IReCaptchaInstance object

IReCaptchaInstance is an object that represents an instance of Recaptcha V3 and is used in the RecaptchaApi.

type IReCaptchaInstance = {
    ready(callback: () => void): void;
    execute(siteKey: string, options: IExecuteOptions): Promise<string>;
    render(container: string | Element, parameters: IRenderParameters): string;
    render(parameters: IRenderParameters): string;
}

IExecuteOptions

Represents an object of execute options containing the following fields:

type IExecuteOptions {
    action: string;
}

IRenderParameters

Represents an object of render parameters containing the following fields:

type IRenderParameters {
    sitekey: string;
    badge?: 'bottomright' | 'bottomleft' | 'inline';
    size?: 'invisible';
    tabindex?: number;
}