From bac22ff47a1cdb21f12f75a506ceca40483d602f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=A7=89?= Date: Thu, 7 Dec 2023 03:28:31 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B9=90=E5=9B=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/main.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/main.go b/bin/main.go index edb73af..e8319a0 100644 --- a/bin/main.go +++ b/bin/main.go @@ -191,7 +191,7 @@ func main() { return } - // Schema + // graphql Schema schema, err := api.NewSchema(api.Config{ Mysql: api.ConfigMysql{ Host: config.GetString("mysql.host"), @@ -211,8 +211,9 @@ func main() { }) http.Handle("/api", handler.New(&handler.Config{ - Schema: &schema, - Pretty: true, + Schema: &schema, + Playground: true, + Pretty: false, })) //http.HandleFunc("/api", func(w http.ResponseWriter, r *http.Request) {