This repo is for an ongoing personal project. It contains frontend, backend and authServer code for a generic FSE code challenge. The project retrieves and displays insurance policy / customer records.
It uses React (Frontend) to connect to an ApolloGraphQL server (Backend). The ApolloGraphQL server connects to a remote REST API datastore. Data is pulled from the datastore, through ApolloGraphQL and then displayed to the user as a React UI.
Basic authentication is handled by AuthServer. Authentication is handled separately from application data.
- The repo for the frontend
- The repo for the backend
- The repo for the REST API `datastore
- Docker containers for the frontend, backend and authServer are available here
- The repo for AuthServer
- Authentication
- AuthServer
- @react-oauth/google (in Frontend)
- react-login-github (in Frontend)
- MongoDB / Mongoose
- Frontend
- React
- React-Table
- React-Date-Picker
- react-flash-message
- Apollo graphQL Client
- Tailwind CSS
- Jest / React Testing Library
- Backend
- ApolloGL Server / datasource-rest
- Datastore
- PostgreSQL
- Node JS / Express / Swagger/OpenAPI
- Mocha / Supertest / Chai
- Instructions are provided in the README files for frontend, backend and AuthServer repos
-
Clone the repo and create the .env files for frontend, backend and authServer.
-
You can run Docker containers for the frontend, the backend and the authServer. Instructions are in the respective README.md files
-
You can also run the whole thing from the project root directory, after you create the .env files for each container (see READMEs for authServer / backend / frontend for how to do this. TLDR: Copy .sample-env to .env for each module). You won't be able to use OAuth to log in, but you can log in / register using username / password and see the app.
docker-compose -p generic-fse up -d
and then run
localhost:3000
in a browser window. It may take a few moments to load.
Stop the Docker containers with:
docker-compose -p generic-fse down
- Google Cloud Deployment
- Develop CI/CD workflow as a separate effort / sandbox (similar to authSandbox)
- Logging
- Expire the auth token / localStorage ...
- Combine with 'Remember Me' functionality
- Browse / Search
- More TypeScript
- Refinements to JWT authorization
- Add authLevel to token
- Check authLevel within the app, for module-level access
- Investigate / resolve data caching
- React Table keeps a memoized copy of the data
- Apollo QL keeps a cache of data
- use the Apollo QL version