react-native: Add support for Pad and TVOS in Platform

This commit is contained in:
Alexis Mangin
2017-09-29 15:10:15 +01:00
parent 616c84c0e7
commit a3634e4796

View File

@@ -5614,7 +5614,7 @@ export interface PixelRatioStatic {
*/
export type PlatformOSType = 'ios' | 'android' | 'windows' | 'web'
interface PlatformStatic {
interface PlatformStatic extends PlatformIOSStatic {
OS: PlatformOSType
Version: number
@@ -5624,6 +5624,11 @@ interface PlatformStatic {
select<T>( specifics: { ios?: T, android?: T} ): T;
}
interface PlatformIOSStatic {
isPad: boolean
isTVOS: boolean
}
/**
* Deprecated - subclass NativeEventEmitter to create granular event modules instead of
* adding all event listeners directly to RCTDeviceEventEmitter.