mirror of
https://github.com/zhigang1992/react-native-firebase.git
synced 2026-04-03 22:48:36 +08:00
[common] add isIOS & isAndroid flags
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
* limitations under the License.
|
||||
*
|
||||
*/
|
||||
import { Platform } from 'react-native';
|
||||
|
||||
export * from './validate';
|
||||
|
||||
@@ -30,3 +31,7 @@ export function promiseDefer() {
|
||||
|
||||
return deferred;
|
||||
}
|
||||
|
||||
export const isIOS = Platform.OS === 'ios';
|
||||
|
||||
export const isAndroid = Platform.OS === 'android';
|
||||
|
||||
Reference in New Issue
Block a user