Apple Sign In on Localhost

I registered the correct redirectURI but now it just sits there. I think it must be posting to that endpoint afterall but I don't see any evidence in the Cloud Logs!

I used Dev Tools to watch the Apple Sign In window and it actually gets an id_token successfully:

{

   "authorization": {

       "id_token": "eyJraWQiOiJCaDZIN3JIVm1iIiwiYWxnIjoiUlMyNTYifQ.eyJpc3MiOiJodHRwczovL2FwcGxlaWQuYXBwbGUuY29tIiwiYXVkIjoibWUuc3VyZmV5LmdvIiwiZXhwIjoxNzExNTQyNDEyLCJpYXQiOjE3MTE0NTYwMTIsInN1YiI6IjAwMDY5OS42MjgzN2QyOTQwOTU0NWU0YWRhNDBmNTU2MTZhYTdmZi4xMjU1IiwiY19oYXNoIjoiR1U3Tjc1dVcya1R3WTliUDdzLUhPUSIsImVtYWlsIjoibWFzdGFAZ2liZG9uLmNvbSIsImVtYWlsX3ZlcmlmaWVkIjp0cnVlLCJhdXRoX3RpbWUiOjE3MTE0NTYwMTIsIm5vbmNlX3N1cHBvcnRlZCI6dHJ1ZX0.zRtuXn8YPliCmyg6QmMKk5k9eTtB7BvK8NtblwocJ5AuVH64Q1iFcm2JVUo-Puh2MSr8fg4DaBtK2KNQC8GYTeapmIrwrvO40D9uxbJzHjJP6T4PHyZbK7cbkSD5HRP-aRE7Y7H8JMpu6TLOb3wbO9hp2lErGSai8xdb35HKPE3yFMH3kufPdbiUVeKErK0m2TPQfrOGGFxLbsPZ3vlSEtgvwIvbu-r6Vemjetoa0SdQHvJDhBhXhw21v3588KSqmqzqtluFqXS-G4_ueWI-laQ_2L9ktoqScSbS3I1jupdWCaxvJ9UpSakttG0tPOhC9Vv_pHaVeYptJs5zaamhXQ",

       "scope": [

           "name",

           "email"

       ],

       "grant_code": "c811571fa33d34ceeaecd135c29614459.0.rwzz.DX-6dtdp5BjI5NFiaSi3cA"

   },

   "authorizedData": {

       "userId": "000699.62837d29409545e4ada40f55616aa7ff.1255"

   },

   "consentRequired": false,

   "enableSignInWithAppleNewFirstTimeRunScreen": false,

   "reAuthorization": false

}

But for some reason the window doesn't close.

Interesting from https://forums.developer.apple.com/forums/thread/128788:

My understanding of the docs is when usePopup is true, no data is posted to the redirect uri but rather the data is returned in a Promise (or DOMEvent) in the page that initiated the pop up.

This thread also goes on to say that the host popup needs to match the host of the redirectURI which is probably why the popup ain't closing on localhost.