This is a simple web application with a Go server/backend and a Vue.js frontend.
The app is designed to make it easy to use any storage, using Hexagonal architecture. Organized based on containers, in order to provide a real working application for development/deployment. Something more than "hello-world" but with the minimum of pre-reqs.
Currently ready for local build using Golang, Vue.js, MongoDB, Docker.
Features:
- View data
- Add to DB
- Delete object from list
- Docker compose wrapped
Email-viewer.mov
Front-end:
- Input field
- Add/remove button
- Validation for non-empty input
- Validation for deletion of non-existent item
- Clearing input after adding/deleting the item
- Comma separated output
Back-end:
- Implemented POST end-point
- Validation for non-empty input
- Validation for existing data input
- Implemented core logic for GET and DELETE end-points
- MongoDB storage
- Communication with MongoDB
- Docker compose
Front-end:
- Validation clean
-
Fetching. - Separate view list option to another component.
- CSV rendering.
Back-end:
- Fix validation
-
Fix GET and DELETE end-points. -
Fix architecture, folder structures. - Apply clean code.
-
Edit status codes view. -
Implement unified entrance. -
Add Makefile. -
Apply hexagonal architecture.
General:
- Add lintering to Makefile.
- Refactor REST.
- Add tests.
- Apply CI/CD.
- Add Swagger.
├── frontend Root of the Vue.js project
│ └── src Vue.js source code
└── server Go backend server
├── cmd Server main / exec
├── internal Storage packages
└── pkg Supporting packages
- Be using Linux, WSL or MACOS, with bash, make etc
- Vue.js - run frontend
- Vite - tooling for frontend
- Go 1.16+ - for running locally
- Docker - for running as a container, or image build
- MongoDB Compass - view collection data after applying changes
Clone the project to any directory where you do development work
git clone https://github.com/moontary/email-viewer.git
Current version GNU Make file is provided to help with running and building locally.
up Start Build
down Stop an remove containers
logs View logs
- The server will listen on port 9090 by default, change this by setting the
config/config.go
variable.
Environmental variables
Frontend:
VITE_URL
- Port for serving connection between containers.
Backend:
Port
- Port to listen on (default:9090
)URI
- Port for DB to listen on (default:27017
)