Closed Angelk90 closed 2 years ago
type something then press CMD + 1
@ospfranco : I would never understand how to use it.
in this way, when can the text sent be large?
When I do CMD + 1, the browser with the email also opens.
@ospfranco : In this case with the call how can you not have problems with cors?
CORS is a browser feature, react-native can do requests to wherever it pleases
@ospfranco , Ok, it would have been nice if the browser worked.
I did a test with the script on react-native
, using my device as an emulator.
It works well, but the console comes back to me with a strange problem:
translatorLanguage.tsx (113:35)
Parsing error: Unexpected token, expected ";"
(ESLint)
111 | try {
112 |
> 113 | length = /^\d+/.exec(json)![0]
| ^
114 |
115 | json = JSON.parse(
116 | json.slice(length.length, parseInt(length, 10) + length.length), (null)
Does that check serve to verify if it is not null
?
Why haven't you used RegExp
?
P.s. That semicolon at the beginning what is it for?
;(json[1][0][0][5] as any).forEach(function (obj: any) {
Link: snack
I don't know which code are you pointing me to, that looks like the code from the translation library but that shouldn't be your concern, I meant more about language handling and the list of supported languages.
https://github.com/ospfranco/google_translate_supported_languages
Will take care of setting translation languages and the whole setting UI for it later
Hi @ospfranco , I wanted to try the translator but I can't find it.