Skip to content

Commit

Permalink
docs(readme): add
Browse files Browse the repository at this point in the history
  • Loading branch information
kiran94 committed May 28, 2022
1 parent b839876 commit b54cd4a
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# go-voyager-graphql

go-voyager-graphql is a small package that allows you to serve the [graphql-voyager](https://github.com/IvanGoncharov/graphql-voyager) graph from a HTTP Server.

## Usage

```go
// Create a new Handler, pass in your GraphQL Endpoint
vh := voyager.NewVoyagerHandler("/graphql")

// Register the Handler
http.Handle("/voyager", vh)
```

Complete Sample can be found in [cmd/server/main.go](./cmd/server/main.go)

## Local Setup

Assuming you are at the root of the repo.

```bash
make install_tools
make build
make test

# Run the Server
# Navigate to http://localhost:8080/voyager
make run_server
```

0 comments on commit b54cd4a

Please sign in to comment.