Skip to content

Can't find variable: TextEncoder #235

Description

@stefaninicnh

Image

Image

React-Native 0.76.6 and "react-native-qrcode-svg": "^6.3.14",

Steps to Reproduce:

Install react-native-qrcode-svg using yarn add react-native-qrcode-svg ("react-native-qrcode-svg": "^6.3.14",)
Import and use the package in a React Native project.
Run the app on Android, and you will encounter the following error:
Can't find variable: TextEncoder

I tried the the README configuration but without success:
https://github.com/Expensify/react-native-qrcode-svg?tab=readme-ov-file#setting-up-the-transformer

System:
OS: macOS 15.2
CPU: (8) arm64 Apple M1
Memory: 161.61 MB / 8.00 GB
Shell:
version: "5.9"
Binaries:
Node:
version: 20.12.2
Yarn:
version: 1.22.22
npm:
version: 10.5.0
Watchman:
version: 2024.11.11.00

Managers:
CocoaPods:
version: 1.15.2
SDKs:
iOS SDK:
Platforms:
- DriverKit 24.2
- iOS 18.2
- macOS 15.2
- tvOS 18.2
- visionOS 2.2
- watchOS 11.2
Android SDK: Not Found
IDEs:
Android Studio: 2024.2 AI-242.23726.103.2422.12816248
Xcode:
version: 16.2/16C5032a
Languages:
Java:
version: 17.0.13
Ruby:
version: 3.3.6
npmPackages:
"@react-native-community/cli":
installed: 15.1.3
wanted: 15.1.3
react:
installed: 18.3.1
wanted: 18.3.1
react-native:
installed: 0.76.6
wanted: 0.76.6
react-native-macos: Not Found
npmGlobalPackages:
"react-native": Not Found
Android:
hermesEnabled: false
newArchEnabled: true
iOS:
hermesEnabled: true
newArchEnabled: false

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions