@dailydrip/apollo-absinthe-upload-link

A network interface for Apollo that enables file-uploading to Absinthe back ends.

Stats

StarsIssuesVersionUpdatedCreatedSize
@dailydrip/apollo-absinthe-upload-link
1.0.33 years ago3 years agoMinified + gzip package size for @dailydrip/apollo-absinthe-upload-link in KB

Readme

Build Status

Apollo-Absinthe-Upload-Link

A network interface for Apollo that enables file-uploading to Absinthe back ends.

Usage

Install via yarn or npm and then use createLink from the package in the construction of your ApolloClient-instance.

import ApolloClient from "apollo-client";
import { createLink } from "apollo-absinthe-upload-link";

const client = new ApolloClient({
    link: createLink({
        uri: "/graphql"
    })
});

Custom headers

Custom headers can be passed through options of the link.

import ApolloClient from "apollo-client";
import { createLink } from "apollo-absinthe-upload-link";

const headers = { authorization: 1234 } 
const client = new ApolloClient({
    link: createLink({
        uri: "/graphql"
    }),
    headers,
});

Usage with React Native

Not tested. Contributing is welcome.

License

MIT (see LICENSE)

Acknowledgements

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.