Fullstack TS application to schedule lectures with Google authentication.
- Next.js
- NextAuth
- TypeScript
- React
- ReduxToolkit
- MongoBD, mongoose
- unit tested (100% coverage)
- PicoCSS - minimal CSS framework
- Formik - for easy form handle
- react-select-search for select with search
- React Icons
-
Clone repo.
-
Install deps (
npm i
). -
Copy
.env.local.example
to.env.local
(this file should not be versioned).- Set up
NEXTAUTH_URL
to your domain (if running locally, set tohttp://localhost:3000/
)
- Set up
-
You will need a MongoDB (you can try Atlas or install one locally).
- Set up connection string in
.env.local
underMONGODB_URI
key.
- Set up connection string in
-
You will need to set up Google OAuth2 to use as auth method.
- NextAuth docs and this article should be helpful.
- Set up auth strings in
.env.local
underGOOGLE_ID
,GOOGLE_SECRET
,SECRET
keys. - Specify allowed email under
ALLOWED_EMAIL
(app is created to be used by one person and mail is just hardcoded).
-
Now app can by run by
npm run dev
.
You can use Vercel.