handleConsentChange is called from the accept and reject buttons in addition to the form submission. The form's onSubmit logic was updated in the JS example, but the react example was passing the method as the prop, which means it would receive the submit event, but it expects an optional visitor consent object.
Solution
(Describe your solution, why this approach was chosen, and what the alternatives/impacts may be)
Background
handleConsentChange
is called from the accept and reject buttons in addition to the form submission. The form's onSubmit logic was updated in the JS example, but the react example was passing the method as the prop, which means it would receive the submit event, but it expects an optional visitor consent object.Solution
(Describe your solution, why this approach was chosen, and what the alternatives/impacts may be)
🎩
Customer Privacy API example
Checklist