Module Platform

type iosIdiom =
| Phone
| Pad
| TV
;
type os =
| IOS(iosIdiom)
| Android
;
exception UnknownPlatform(string);
let os : unit => os;

Raises UnknownPlatform for non-standard platforms such as "web" from react-native-web

let equals : os => bool;
exception UnknownVersion;
let version : unit => int;

Raises UnknownVersion if version is undefined, i.e. in react-native-web