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

Guidecolor doesn't work as string on iOS #39

Open
corymsmith opened this issue May 25, 2017 · 1 comment
Open

Guidecolor doesn't work as string on iOS #39

corymsmith opened this issue May 25, 2017 · 1 comment

Comments

@corymsmith
Copy link

You have to use processColor first which doesn't match what the docs say. It looks like a similar fix was added for Android a while back. b84d21c

@billdozr
Copy link

billdozr commented Mar 14, 2018

This is how to directly use processColor for iOS in the mean time to set guideColor:

import {
  Platform,
  processColor
} from 'react-native'

let conf = {
  guideColor: Platform.OS === 'ios' ? processColor(myColor) : myColor
  ...
}

CardIOModule.scanCard(conf).then(card => { ... })

Tested with react-native v0.53.3 (but should work with other versions).

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

No branches or pull requests

3 participants