A very simple example of how to have a separate frontend and backend sign in through google
An example of how to have a frontend api and a backend with google OAuth2
create a new project create a new Oauth credential add localhost:3002/auth_callback as the redirect uri download credentials as JSON
cd client npm i copy config.example.js to config.js and add your credentials from the step above npm run start
cd server npm i copy config.example.js to config.js and add your credentials from the step above npm run start
https://aidanlovelace.com/2019/06/19/how-to-setup-google-oauth2-login-with-express/ https://github.com/AidanLovelace/Express-Google-OAuth2-Tutorial