Skip to content

Latest commit

 

History

History
38 lines (31 loc) · 1.09 KB

README.md

File metadata and controls

38 lines (31 loc) · 1.09 KB

About

This is the corresponding repository to article on how to set up AppSync with offline support and react hooks.

Setup

git clone https://github.com/willsamu/appsync-offline-mutations.git && cd appsync-offline-mutations
npm install -g @aws-amplify/cli expo-cli

Configure global amplify settings with amplify configure

In the appsync-offline-mutations directory, initialize the amplify project:

amplify init

Add a Cognito User Pool with default settings:

amplify add auth

Attach a GraphQL API (default settings / todo schema) to it:

amplify add api

Finally run

amplify push

Install dependencies using npm install or yarn install.

Start the the project on an emulator or on your mobile device using the Expo app (IOS / Android):

expo start