This project aims to use neelance/graphql-go to build a starter web application. This project would be continuously under development. Pull request is welcome.
- Integrated with sqlx
- Integrated with graphql-go
- Use go-bindata to generate Go code from .graphql file
- Use psql
- Integrated with dataloader
- Add authentication & authorization
- Add unit test cases
- Support subscription
-
Install go-bindata
go get -u github.com/jteeuwen/go-bindata/...
-
Setup GOPATH
For example: MacOS
export GOPATH=/Users/${username}/go export PATH=$PATH:$GOPATH/bin
-
Run the following command at root directory to generate Go code from .graphql file
go-bindata -ignore=\.go -pkg=schema -o=schema/bindata.go schema/...
There would be bindata.go generated under
schema
folder -
Start the server
go build server.go
- Run Unit Tests
go test