Exposure
This is a social media app built using React Native and a GraphQL API. The app allows users to connect with friends, share updates and photos, and engage with others. Requirements
Getting Started
Clone this repo
git clone https://github.com/HelixHEX/exposure-app
Install the required dependencies by running
yarn install
Start the app by running
expo start
Features
- View user profiles
- Post photos
- Like and comment on posts
API Reference
The app connects to a GraphQL API (repo) for performing operations such as querying and mutating data. As of now the endpoint is hardcoded to the public api hosted on AWS. If you would like to change the endpoint, you can do so in this file
Here are some examples of the types of operations that can be performed using the API:
Full list of queries and mutations
Querying data
query Comments($postId: Int!) {
comments(post_id: $postId) {
id
comment
createdAt
profile {
id
username
}
}
}
This query gets all comments for a particular post.
Mutating data
mutation CreateComment($comment: String!, $postId: Int!) {
createComment(comment: $comment, post_id: $postId) {
comment {
comment
}
}
}
This mutation creates a new comment for a particular post.