Im trying to using stripe-react-native (with expo and using android) library but immediately I use the StripeProvider I got this error (I followed the Docs):
TypeError: null is not an object (evaluating '_NativeStripeSdk["default"].initialise')
This error is located at:
in StripeProvider (at App.js:35)
in EnsureSingleNavigator (at BaseNavigationContainer.tsx:409)
in ForwardRef(BaseNavigationContainer) (at NavigationContainer.tsx:91)
in ThemeProvider (at NavigationContainer.tsx:90)
...
This is where I use it:
...
import { StripeProvider } from '@stripe/stripe-react-native'
//pass the ref to your navigation container
import { PersistGate } from 'redux-persist/integration/react'
import { store, persistor } from './store'
import { Provider } from 'react-redux'
import { AppTab } from './Navigation'
export default function App() {
return (
<Provider store={store}>
<PersistGate loading={null} persistor={persistor}>
<NavigationContainer>
<StripeProvider
publishableKey="pk_live_L4zEu37Als6Z..."
>
<AppTab />
</StripeProvider>
</NavigationContainer>
</PersistGate>
</Provider>
)
}
my package.json:
...
"expo": "~41.0.1",
"expo-status-bar": "~1.0.4",
"react": "16.13.1",
"react-dom": "16.13.1",
"react-native": "https://github.com/expo/react-native/archive/sdk-41.0.0.tar.gz",
"react-native-web": "~0.13.12",
...
"@stripe/stripe-react-native": "^0.1.2",
....
I dont find anything on this problem can someone help me seeing what im doing wrong? thanks!