import { IRootState } from '@models' ; import { connect , MapDispatchToProps } from 'react-redux' ; import { navigate , pop } from '@navigator/NavigationService' ; import { Contact } from './Contact' ; export interface IContactProps { navigation : { state : { params : number ; } ; } ; } export const ContactScreen = connect ( ( state , props ) => ( { contact : state . contacts [ props . navigation . state . params ] , } ) , ( dispatch ) => ( { pop , navigate : ( routeName , contactId ) => ( ) => navigate ( routeName , contactId ) , } ) ) ( Contact ) ;