Код: Выделить всё
let privacyConfig = new UserPrivacyOptions(DataCollectionLevel.Off, true);
requestTrackingPermission()
.then((trackingStatus) => {
if (trackingStatus === "authorized") {
console.log("Access granted");
} else {
console.log("Access revoke");
Dynatrace.applyUserPrivacyOptions(privacyConfig);
}
})
.catch((error) => {
console.error("Tracking Permission Error", error);
});
Подробнее здесь: https://stackoverflow.com/questions/793 ... -app-track
Мобильная версия