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

Exclude this on ios platform #8

Open
lakpriya1s opened this issue Sep 26, 2023 · 0 comments
Open

Exclude this on ios platform #8

lakpriya1s opened this issue Sep 26, 2023 · 0 comments

Comments

@lakpriya1s
Copy link

I have a React Native Expo app that uses this package. It works perfectly on Android devices. However, when I attempt to run the same code on the iOS platform, I encounter the following error:

Error: The package 'react-native-usb-serialport-for-android' doesn't seem to be linked. Make sure: 

- You have run 'pod install'
- You rebuilt the app after installing the package
- You are not using Expo managed workflow

I tried below solutions but they are not working as expected.

In package.json

"expo": {
    "autolinking": {
      "ios": {
        "exclude": [
          "react-native-usb-serialport-for-android"
        ]
      }
    }
  }

In react-native.config.js

module.exports = {
   dependencies: {
      'react-native-usb-serialport-for-android': { platforms: { ios: null } } 
  } 
}

Suggest me a workaround to exclude this lib from ios platform while using in android!

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

1 participant