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

Can't not receive url deeplink IOS when click on notification metadata #2260

Open
vietdung97 opened this issue Feb 28, 2024 · 1 comment
Open

Comments

@vietdung97
Copy link

Describe the Bug
Hi everyone,
I can't get url data from Link on iOS when I click on the metadata notification like Android (Android works perfectly)
So, how do I get the string "trackplayer://notification.click" like Android?
Code To Reproduce

  useEffect(() => {
    async function deepLinkHandler(data: {url: string | null}) {
      if (data.url === 'trackplayer://notification.click') {
        //
      }
    }

    const listener = Linking.addEventListener('url', deepLinkHandler);

    Linking.getInitialURL().then(url => deepLinkHandler({url}));

    return () => {
      listener.remove();
    };
  }, []);
=> nothing happens on callback function of listener

Environment Info:
Paste the exact react-native-track-player version you are using: 4.0.1
Real device
What OS are you running: IOS 17

@vietdung97 vietdung97 added the Bug label Feb 28, 2024
Copy link
Contributor

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale label May 29, 2024
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

1 participant