Smart React util imports#2455
Conversation
|
My PR will help #2396 too, it's not an either or situation, both can work great, and since that is a compile time if/else situation it won't affect the performance either. |
|
@SudoPlz I understand that you're trying to resolve compiler issues w/ this PR, but I'm not sure I really understand how it resolves the issue that you're facing that #2396 would not. I think it'd be preferable to stick with the When used via Can you try pulling and using #2396 in your project as it should resolve the issue that you're trying to address in this PR as well. If it doesn't, can you post an example GitHub project that includes the proper |
|
@wbyoung you're right, I did pull #2396 here https://github.com/SudoPlz/react-native-maps/tree/bin and everything works fine now (I had to add a few missing Keep in mind in this PR I also included my code too. I'll close that PR since I don't have the time to investigate further atm, but hopefully that issue will help someone in the future. |
|
@SudoPlz yeah, it depends on what branch of the code base you're working off of. @chrise86 did the same thing off of a It's really just that all the Google Maps files need it (which I'm sure you already figured out, but the comment may be helpful for others who come here), but it depends on which branch you're including the changes. The open PR is based off of |
What issue is this PR fixing?
This PR changes the way React components/utils/objects are imported so that imports work both with
react-native linkANDcocoapodsReact embedded projects.How did you test this PR?
Tested it on my react-native link project and it works.