Skip to content

Commit 73aafcd

Browse files
authored
Merge pull request #2 from ZEXSM/feature/docs
add docs
2 parents 5d826cc + 661417b commit 73aafcd

File tree

3 files changed

+44
-2
lines changed

3 files changed

+44
-2
lines changed

README.md

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,41 @@
1-
# GraphQL.Tool.Embedded
1+
# GraphQL.Tool.Embedded
2+
Library of GraphQL tools such as GraphQL Playground and GraphQL Voyager.
3+
4+
[![Build Status](https://travis-ci.com/ZEXSM/GraphQL.Tool.Embedded.svg?branch=main)](https://travis-ci.com/ZEXSM/GraphQL.Tool.Embedded)
5+
[![Nuget Status](https://img.shields.io/nuget/dt/GraphQL.Tool.Embedded.svg)](https://www.nuget.org/packages/GraphQL.Tool.Embedded)
6+
7+
## Usage
8+
9+
Default use
10+
11+
```csharp
12+
app.UseEndpoints(endpoints =>
13+
{
14+
...
15+
endpoints.MapGraphQLPlayground();
16+
endpoints.MapGraphQLVoyager();
17+
});
18+
```
19+
20+
Using with settings
21+
22+
```csharp
23+
app.UseEndpoints(endpoints =>
24+
{
25+
...
26+
// https://github.com/graphql/graphql-playground#settings
27+
var playgroundOptions = PlaygroundOptions
28+
{
29+
...
30+
}
31+
32+
// https://github.com/APIs-guru/graphql-voyager#properties
33+
var voyagerOptions = VoyagerOptions
34+
{
35+
...
36+
}
37+
38+
endpoints.MapGraphQLPlayground("/ui/playground", playgroundOptions);
39+
endpoints.MapGraphQLVoyager("/ui/voyager", VoyagerOptions);
40+
});
41+
```

src/GraphQL.Tool.Embedded/GraphQL.Tool.Embedded.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<PackageProjectUrl>https://github.com/ZEXSM/GraphQL.Tool.Embedded</PackageProjectUrl>
1313
<RepositoryUrl>https://github.com/ZEXSM/GraphQL.Tool.Embedded</RepositoryUrl>
1414
<RepositoryType>git</RepositoryType>
15-
<PackageTags>graphql;graphql-playground;graphql-voyager</PackageTags>
15+
<PackageTags>graphql;graphql-playground;graphql-voyager;graphql-tools;graphql-dotnet</PackageTags>
1616
<Authors>ZEXSM</Authors>
1717
<Description>Library of GraphQL tools such as GraphQL Playground and GraphQL Voyager.</Description>
1818
</PropertyGroup>

src/GraphQL.Tool.Embedded/Voyager/VoyagerOptions.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ public VoyagerOptions()
1212
["Accept"] = MediaTypeNames.Application.Json,
1313
["Content-Type"] = MediaTypeNames.Application.Json,
1414
};
15+
16+
// TODO implement https://github.com/APIs-guru/graphql-voyager#properties
1517
}
1618
}
1719
}

0 commit comments

Comments
 (0)