Please provide the following:
- SDK Version: 40.0.0
- Platforms(Android/iOS/web/all): IOS
- Add the appropriate “Tag” based on what Expo library you have a question on. expo-linking
I am running Linking.getInitialUrl() in the constructor of my home screen. It works as expected when someone uses a deep link to open my app, which navigates the user to a specific screen based on the query params. The problem is that if the user closes and re-opens the app, getInitialUrl() does not reset, in other words, it returns the same path and query params every time the app is opened, regardless if the user clicked a link or not, resulting in my app wrongly navigating every time it’s opened
Shouldn’t the data from getInitialUrl() reset when the user closes the app?
Here is the function i call in the constructor:
handleInitialUrl = async () => {
Linking.getInitialURL()
.then(url => {
let { path, queryParams } = Linking.parse(url);
// const { faceId, climbId } = queryParams;
// navigate to screen
})
.catch(err => alert(err));
};