diff --git a/types/react-native-communications/index.d.ts b/types/react-native-communications/index.d.ts index d50ce419a0..a6c572174d 100644 --- a/types/react-native-communications/index.d.ts +++ b/types/react-native-communications/index.d.ts @@ -1,11 +1,12 @@ // Type definitions for react-native-communications 2.2 // Project: https://github.com/anarchicknight/react-native-communications // Definitions by: HuHuanming +// Paito // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 export function phonecall(phoneNumber: string, isPrompt: boolean): void; -export function email(to: string, cc: string, bcc: string, subject: string, body: string): void; +export function email(to: string[] | null, cc: string[]| null, bcc: string[] | null, subject: string | null, body: string | null): void; export function text(phoneNumber?: string | null, body?: string | null): void; export function textWithoutEncoding(phoneNumber?: string | null, body?: string | null): void; export function web(address?: string | null): void; diff --git a/types/react-native-communications/react-native-communications-tests.ts b/types/react-native-communications/react-native-communications-tests.ts index 754f8a5a0c..edad4ad933 100644 --- a/types/react-native-communications/react-native-communications-tests.ts +++ b/types/react-native-communications/react-native-communications-tests.ts @@ -2,7 +2,7 @@ import { phonecall, email, text, textWithoutEncoding, web } from 'react-native-c phonecall('123456789', true); -email('a@example.com', 'a@example.com', 'a@example.com', 'subject', 'body'); +email(['a@example.com'], null, ['a@example.com'], 'subject', null); text(); text('123456789');