Removes the current policy from the site visitor's browser and resets the site visitor's consent policy to the default policy for the site.
function resetConsentPolicy(): Promise<void>;
import { consentPolicy } from "wix-window-frontend";
// ...
consentPolicy
.resetConsentPolicy()
.then((policy) => {
console.log("The policy is now set to the default site policy.");
return policy;
})
.catch((error) => {
console.error(error);
});
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.