# README
go-altair
Altair GraphQL Client Go HTTP Handler
Installation
go get github.com/hamidfzm/go-altair
Usage
package main
import (
"net/http"
)
func main() {
config := &altair.Config{
DefaultWindowTitle: "Mafia Altair",
Endpoint: endpoint,
Force: false,
Headers: []altair.Header{
{
Key: echo.HeaderAuthorization,
Value: "Bearer <token>",
},
},
}
http.Handle("/altair", altair.Handler(config))
http.ListenAndServe(":8080", nil)
}
License
Check LICENSE file for more information.
# Functions
EchoHandler returns an echo.HandlerFunc that serves the Altair GraphQL IDE.
Handler returns an http.HandlerFunc that serves the Altair GraphQL IDE.