Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Property 'TextDecoder' doesn't exist #93

Open
errorstudent opened this issue Dec 24, 2024 · 3 comments
Open

Property 'TextDecoder' doesn't exist #93

errorstudent opened this issue Dec 24, 2024 · 3 comments

Comments

@errorstudent
Copy link

errorstudent commented Dec 24, 2024

Hi All,
I'm trying to generate keys, but I got error Property 'TextDecoder' doesn't exists.

The code is:

const keys = await RSA.generate(4096);

Simulator Screenshot - iPhone 16 - 2024-12-24 at 12 38 10

@nicolasquintanam
Copy link

I'm currently with the same problem with react native 0.75.4 and old achitecture

@nicolasquintanam
Copy link

this happens only with the version 2.5.0, I tried with 2.4.4 and it works

@holmesjr
Copy link

I've worked around this by explicitly installing the "text-encoding" polyfill.

import 'text-encoding' in the file where you're using RSA and you're good to go.

The problem will also go away if you update expo to SDK 52, as this will use the latest Hermes engine which fixed this (assuming you're using expo).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants