next.jsexpress.jsmongodbapollographql
-
Create
.envfile and paste below code.PORT: 3000, GOOGLE_CLIENTID: Your Google client ID, GOOGLE_CLIENTSECRET: Your Google client screct code, MONGO_URI: Your mongo uri, SESSION_SECRET: your session secret LOCAL_URL = http://localhost:3000/ PRODUCTION_URL = Your Production URL LOCAL_CALLBACK_URL = Your local callback URL PRODUCTION_CALLBACK_URL = Your Production callback URL -
To get Google clientID and Google client secrect you must create oauth in Google Developer Console
-
Authentication is done through google-oauth20.
-
Run the following command
npm install -
To run client run below command
npm run client
-
To run both Client and Server run below command
npm run server
Application design will look as dev.to with some little changes in styles.