Open shebinjoseph388 opened 7 years ago
I'm getting the same error trying to use this module with create-react-app. From what I can tell, its a webpack issue based on how a library is being "required". It can be worked around by ejecting, anyone have a notion on how to resolve without that?
For the browser support i have used Browserify to convert the code, as a result , the converted file translate.js its about 300 kb and when i use that ı got an error:
Uncaught TypeError: Cannot read property 'prototype' of undefined at patch (translater.js:10974) at Object.<anonymous> (translater.js:10835) at Object.66../fs.js (translater.js:11072) at s (translater.js:1) at translater.js:1 at Object.56.dot-prop (translater.js:9695) at s (translater.js:1) at translater.js:1 at Object.62.configstore (translater.js:10159) at s (translater.js:1)
The same trouble!
Same problem here, any update?
It has to do with the configstore
module, which is used by the google-translate-token
module to store the token. configstore
uses graceful-fs
module that is not compatible with browserify (see https://stackoverflow.com/a/42012528/2031954).
I could get away with a hack that involved editing the source code of google-translate-token
to make it use another library for token persistence (I chose data-store
). Little change is required (essentially, I had to change only the require
line) , but nonetheless it is not a clean solution.
same problem
Facing the same problem, was anyone able to get around it?
TypeError: fs$ReadStream is undefined