From acf80e640c584bf4019cfaf9356ee44b09e7dc99 Mon Sep 17 00:00:00 2001 From: Satyajit Sahoo Date: Mon, 13 May 2019 14:40:47 +0200 Subject: [PATCH] Fix type of active prop in typescript definitions (#97) The TS definitions specify the prop as a boolean, but passing a boolean causes a crash. --- src/screens.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/screens.d.ts b/src/screens.d.ts index ccf85800..f9334e8e 100644 --- a/src/screens.d.ts +++ b/src/screens.d.ts @@ -3,13 +3,13 @@ declare module 'react-native-screens' { import { ComponentClass } from 'react'; - import { ViewProps } from 'react-native'; + import { ViewProps, Animated } from 'react-native'; export function useScreens(shouldUseScreens?: boolean): void; export function screensEnabled(): boolean; export interface ScreenProps extends ViewProps { - active?: boolean; + active?: 0 | 1 | Animated.AnimatedInterpolation; onComponentRef?: (view: any) => void; } export const Screen: ComponentClass;