Takahiro Kudo
Posted on March 21, 2021
I did graphql-go Tutorial
and had a little trouble. Therefore I share my note.
Getting started
https://www.howtographql.com/graphql-go/1-getting-started/
validation failed: packages.Load
error occured.
To fix it, setup go module.
% cd <project dir>
% go mod init
% go get github.com/99designs/gqlgen
# This module is needed.
% go get github.com/vektah/gqlparser/v2
%gqlgen init
Database
https://www.howtographql.com/graphql-go/4-database/
server.go
needs go-chi
.
% go get github.com/go-chi/chi
Testing query and mutation.
We can test on browser UI which URL is http://localhost:8080
.
Codes
💖 💪 🙅 🚩
Takahiro Kudo
Posted on March 21, 2021
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.
Related
undefined Introducing astjson: Transform and Merge JSON Objects with Unmatched Speed in Go
November 29, 2023