UNPKG

react-google-translate-mj

Version:

A React package for automatic website translation using Google Translate API

11 lines (10 loc) 270 B
export interface TranslateOptions { from?: string; to: string; text: string; } export interface TranslateError extends Error { code?: string; response?: any; } export declare function translate({ from, to, text }: TranslateOptions): Promise<string>;