google-translate-api icon indicating copy to clipboard operation
google-translate-api copied to clipboard

TypeError: Cannot read property 'toString' of undefined

Open merrysabreezy opened this issue 6 years ago • 5 comments

screenshot 162 screenshot 163

How to solve this problem in react-native?

merrysabreezy avatar Dec 28 '18 10:12 merrysabreezy

Same problem here, but with react js 16.7.0, and on import.

gabrii avatar Jan 06 '19 14:01 gabrii

This isn't actually an issue of this repo. It's an issue related to you using "" instead of '' where you're using it.

rawr51919 avatar Mar 19 '19 12:03 rawr51919

I am receiving the exact same error and I'm not using double quotes @coltongit.

return translate('Test', {from: 'en', to: 'fr'}).then(res => {
      return res.text;
    }).catch(err => {
      console.error(err);
    });

dallashuggins avatar May 26 '19 00:05 dallashuggins

I am receiving the exact error while using one quote

SallyHabib97 avatar Jul 09 '19 16:07 SallyHabib97

This library does not work in web page context. See: https://github.com/vitalets/google-translate-api#does-it-work-from-web-page-context

vitalets avatar Jul 11 '19 12:07 vitalets