@dailydrip/apollo-absinthe-upload-link

1.0.3 • Public • Published

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

Readme

Keywords

none

Package Sidebar

Install

npm i @dailydrip/apollo-absinthe-upload-link

Weekly Downloads

2

Version

1.0.3

License

MIT

Unpacked Size

8.66 kB

Total Files

6

Last publish

Collaborators

  • dailydripdevs
  • franzejr
  • knewter