Created
December 17, 2018 23:31
-
-
Save adrianhall/6f29077016d88a73bfbb29fcfa63db81 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import gql from 'graphql-tag'; | |
import AWSAppSyncClient, { AUTH_TYPE } from 'aws-appsync'; | |
import aws_config from './aws-exports'; | |
import App from './src/App'; | |
const client = new AWSAppSyncClient({ | |
url: aws_config.aws_appsync_graphqlEndpoint, | |
region: aws_config.aws_appsync_region, | |
auth: { | |
type: aws_config.aws_appsync_authenticationType, | |
apiKey: aws_config.aws_appsync_apiKey, | |
} | |
}); | |
const WithProvider = () => ( | |
<ApolloProvider client={client}> | |
<Rehydrated> | |
<App /> | |
</Rehydrated> | |
</ApolloProvider> | |
) | |
export default WithProvider |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment