SteffeyDev / react-native-popover-view

A well-tested, adaptable, lightweight <Popover> component for react-native
MIT License
613 stars 92 forks source link

The global "__expo" and "Expo" objects will be removed in SDK 41 #102

Closed erbud closed 3 years ago

erbud commented 3 years ago

Is your feature request related to a problem? Please describe. The global "__expo" and "Expo" objects will be removed in SDK 41.

Describe the solution you'd like Use a module import Constants (expo-constants) rather than a deprecated global API.

SteffeyDev commented 3 years ago

I don't understand this, you're going to have to be way more specific. AFAIK I don't use any expo-specific code.

erbud commented 3 years ago

@SteffeyDev when I installing and using react-native-popover-view:

<Popover
    from = {(
        <TouchableOpacity>
            <Text> {date.day} </Text>
        </TouchableOpacity>
    )}>
    …
</Popover>

The following warning is displayed when activating and displaying the popover:

_The global "_expo" and "Expo" objects will be removed in SDK 41. Learn more about how to fix this warning: https://expo.fyi/deprecated-globals

I'm trying to debug to confirm what causes the warning

Regards.

SteffeyDev commented 3 years ago

If you remove all the Popovers from your app, but nothing else, does the warning go away?

erbud commented 3 years ago

@SteffeyDev yes, the warning only is displayed when show and hide the Popover. On tap the component (to show) and on tap outside the Popover (to hide).

SteffeyDev commented 3 years ago

Well, I just searched my source code to be sure and am not using Expo globals (I don't even have expo as a dependency). That means that either react-native-safe-area-view (my only dependency) is using Expo globals (I am ditching this library soon anyways), Expo is bugging out and giving bad warning, or the issue is in your code or another dependency you are using. Either way, nothing I can do, so going to close this. You are free to look through the source code if you would like, it is all here on GitHub for you to review.

erbud commented 3 years ago

@SteffeyDev sorry bro., the warning is triggered by the sentry-expo package …