-
-
Save amandeepmittal/e0d893f74ffa8e393ceb5fa64adf61f6 to your computer and use it in GitHub Desktop.
This file contains 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
// App.js | |
// ... after other imports | |
import { listNotes } from "./graphql/queries" | |
// ... inside App component | |
async componentDidMount() { | |
const result = await API.graphql(graphqlOperation(listNotes)) | |
this.setState({ notes: result.data.listNotes.items }) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment