Engage.identity(eventData[, extensionData])
The identity() function sends an IDENTITY event. The IDENTITY event is used to resolve the identity of an anonymous user of your app and turn them into a known user.
Here's an example of how to use the identity() function to send the email address that a user enters in a form. In a React app, you can capture form data using the State Hook.
components/Form.jsx: