# README
go-gql-blogs
The blog application implemented in GraphQL with gqlgen
.
How To Use
There are two branches in this repository:
local-storage
for implementation with local storage.main
for implementation with MongoDB database.
-
Clone the repository.
-
If
local-storage
branch is chosen, run the application with this command.
go run server.go
- If
main
branch is chosen, copy the.env
file.
cp .env.example .env
-
Configure the MongoDB database configuration inside the
.env
file. -
Run the MongoDB database server or make sure the MongoDB database is online.
-
Run the application with this command.
go run server.go
- Test the application with this command.
go test