redirecting to Google OAuth flow in progressive web app : <p>I've been working on an app using React and Next.js, currently adding PWA support.</p>

<p>Users log in to the app via the Google OAuth flow. I was originally using the JS client which utilizes a pop-up window, but that ran into errors in the PWA. I'm now using the normal OAuth flow by redirecting the user to Google's OAuth URL.</p>

<p>This works fine in the browser. In the standalone PWA on iOS, it opens the OAuth page in a new Safari window. This means that the OAuth flow is carried out in Safari, and at the end the user is left using the app in Safari rather than the standalone PWA.</p>

<p>I'm redirecting using this method:</p>

<pre><code>export function setHref(newLocation: string) {
  window.location.href = newLocation;
}
</code></pre>

<p>This even looks to be the method everyone recommends to avoid pop-ups when redirecting in your PWA. Has this changed recently? Or is there another method to carry out redirects/OAuth flows inside a standalone progressive web app?</p>
