question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Remove the manifest from iOS to allow OAuth redirect to works

See original GitHub issue

Lot of people are having issue with redirect at OAuth flow when using the apple-mobile-web-app-capable feature of iOS:

I believe it can be solved by changing the: <link rel="manifest" href="manifest.json"> to <link rel="no-on-ios" href="manifest.json"> when on iOS.

It prevent the iOS Safari to process the manifest (which cause the bug)

So, i believe that this pice of code could be inside pwacompat.js to allow many of PWAs use OAuth login:

   var iOS = !!navigator.platform && /iPhone/.test(navigator.platform);
   if(iOS) {
      document.querySelector('link[rel="manifest"]').setAttribute("rel", "no-on-ios");
   }

At least until apple fix this issue (don’t know where or if is been tracked).

https://forums.developer.apple.com/thread/100524

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:8
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

6reactions
samthorcommented, Jan 26, 2019

In exciting news, looks like new Safari betas might resolve this issue.

1reaction
maku-zuhlkecommented, Apr 5, 2019

Thanks @samthor. I can confirm that iOS 12.2.0 fixes the issue for us. 🎉🎉🎉

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do I remove the web address in a display:standalone IOS ...
I stumbled across online that safari's full screen PWA apps will show the URL bar after a redirection to a different domain, to...
Read more >
OAuth 2.0 for Mobile & Desktop Apps - Google Developers
Important: The loopback IP address redirect option is DEPRECATED for the Android, Chrome app, and iOS OAuth client types.
Read more >
Authentication - Expo Documentation
Under "Valid OAuth Redirect URIs" add https://localhost:19006 and any other web URLs you may want to add. Press "Save Changes" in the footer....
Read more >
oauth2_client | Flutter Package - Pub.dev
Flutter library for interacting with OAuth2 servers, with classes for transparent authorized requests, secure OAuth token storage, automatic token refeshing ...
Read more >
Redirect Users - Auth0
To learn more about how the redirect_uri works, see OAuth 2.0 ... On (SSO) to allow your user to maintain an authentication session...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found