Identity Verification
getting started
mobile - client-side SDKs
React
Steps to integrate the Web SDK into React application.

Verification Flow

1. Installation

To install the Preventor Web SDK, add the following to your project’s:
  1. 1.
    Add https://unpkg.com/@preventor/button in your public/index.html.
1
<script type="module" src="https://unpkg.com/@preventor/button"></script>
Copied!
2. Setup the button in your component file
1
import React, { useEffect, useRef } from "react";
2
3
export default function App() {
4
const pvtButtonRef = useRef(null);
5
useEffect(() => {
6
const pvtButton = pvtButtonRef.current;
7
pvtButton.addEventListener("loaded", () => {
8
pvtButton.initialize(YOUR_CONFIGURATION)
9
});
10
}, []);
11
12
return <pvt-button ref={pvtButtonRef}></pvt-button>;
13
}
Copied!
You have successfully installed the Preventor Web SDK!