Skip to content

Commit

Permalink
build: fix typescript build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
artyorsh authored Jun 21, 2019
1 parent 981d5c8 commit 0d0a784
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 65 deletions.
10 changes: 10 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"@types/lodash.merge": "^4.6.6",
"@types/react": "^16.8.19",
"@types/react-native": "^0.57.60",
"@types/react-navigation": "^3.0.7",
"@types/react-test-renderer": "^16.8.1",
"babel-core": "^7.0.0-bridge.0",
"babel-jest": "^23.6.0",
Expand Down
22 changes: 11 additions & 11 deletions src/framework/ui/support/typings/type.ts
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
import {
NativeSyntheticEvent,
GestureResponderEvent,
NativeScrollEvent,
TextInputFocusEventData,
NativeSyntheticEvent,
TextInputEndEditingEventData,
TextInputFocusEventData,
TouchableOpacityProps,
GestureResponderEvent,
} from 'react-native';

export type ScrollEvent = NativeSyntheticEvent<NativeScrollEvent>;
export type InputFocusEvent = NativeSyntheticEvent<TextInputFocusEventData>;
export type InputEndEditEvent = NativeSyntheticEvent<TextInputEndEditingEventData>;

export type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
export type Omit<T, K> = Pick<T, Exclude<keyof T, K>>;
export type Override<T, U> = Omit<T, keyof U> & U;

// @ts-ignore: props override
export interface TouchableIndexedProps extends TouchableOpacityProps {
export type TouchableIndexedProps = Override<TouchableOpacityProps, {
onPress?: (index: number, event: GestureResponderEvent) => void;
onPressIn?: (index: number, event: GestureResponderEvent) => void;
onPressOut?: (index: number, event: GestureResponderEvent) => void;
onLongPress?: (index: number, event: GestureResponderEvent) => void;
}
}>;

export type ScrollEvent = NativeSyntheticEvent<NativeScrollEvent>;
export type InputFocusEvent = NativeSyntheticEvent<TextInputFocusEventData>;
export type InputEndEditEvent = NativeSyntheticEvent<TextInputEndEditingEventData>;
60 changes: 9 additions & 51 deletions src/playground/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions src/playground/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,5 @@
"react": "^16.8.3",
"react-native": "https://github.com/expo/react-native/archive/sdk-33.0.0.tar.gz",
"react-navigation": "^3.11.0"
},
"devDependencies": {
"@types/react-navigation": "^3.0.7"
}
}

0 comments on commit 0d0a784

Please sign in to comment.