DartpolloClient constructor
DartpolloClient(
- String graphQLEndpoint, {
- Client? httpClient,
Instantiate an DartpolloClient.
DedupeLink
and HttpLink
are included.
To use different Link
create an DartpolloClient with DartpolloClient.fromLink.
Implementation
factory DartpolloClient(
String graphQLEndpoint, {
http.Client? httpClient,
}) {
final httpLink = HttpLink(
graphQLEndpoint,
httpClient: httpClient,
);
return DartpolloClient.fromLink(
Link.from([
DedupeLink(),
httpLink,
]),
).._httpLink = httpLink;
}