In the order that decides whether you can use it — starting with the one that is most often assumed the other way round.
import Intune, { EnrollmentStatus } from 'react-native-intune';
await Intune.configure({
clientId: cfg.aadClientId,
tenantId: cfg.aadTenantId,
authority: cfg.aadAuthority,
redirectUri: cfg.aadRedirectUri,
});
const { enrollment } = await Intune.signInAndEnroll();
// Only 'failed' means block. 'notLicensed' and 'notTargeted' are legitimate
// employees whose app simply runs unmanaged.
if (enrollment.status === EnrollmentStatus.Failed) {
blockCorporateData();
}
Installing the package takes a minute. Wiring it into your project takes about an hour — and the guides say which steps fail silently, so you do not find out on a device.