Testing loginWithGoogle (oauth) on localhost via a device

Hello guys, my login with google is working fine in a browser, but when I go to my phone and load it there through local ip (e.g. I cannot login anymore. I get this error (on image) that it cannot connect to server, I guess localhost is not recognized on my phone.

I also found similar unanswered question on the forum: How can I access an app that requires Google login on my mobile device that is running on my local machine?

Has anybody experience with this? Thanks a lot.