Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mrbooi/react-hooks-apollo-graphql
Small Applications that use react-hooks with Apollo and graphql with Rest API
https://github.com/mrbooi/react-hooks-apollo-graphql
Last synced: about 4 hours ago
JSON representation
Small Applications that use react-hooks with Apollo and graphql with Rest API
- Host: GitHub
- URL: https://github.com/mrbooi/react-hooks-apollo-graphql
- Owner: MrBooi
- Created: 2020-04-18T17:50:19.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-12-12T12:44:54.000Z (almost 2 years ago)
- Last Synced: 2023-03-03T04:03:19.774Z (over 1 year ago)
- Language: JavaScript
- Homepage: https://frozen-thicket-53665.herokuapp.com/
- Size: 1.19 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 14
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Chuck Norris Jokes App
This is a single Page App builtwith react and chucknorris api which generated a random joke for a selected categorie.This App is Structured into two parts It have Server side and client side.
Server:
1. It have Apollo GraphQL API
2. GraphQL API wraps [ChuckNorris.io](https://api.chucknorris.io/) API
3. GraphQL API have a Query type that resolves all Categories ([https://api.chucknorris.io/jokes/categories](https://api.chucknorris.io/jokes/categories))
4. GraphQL API have a Query type that resolves a random joke given a Category as an argument ([https://api.chucknorris.io/jokes/random?category={category}](https://api.chucknorris.io/jokes/random?category=%7Bcategory%7D))Client:
1. Is a Single Page App (SPA)
2. SPA consume the above GraphQL API
3. SPA have a home page with a list of categories
4. When a category is clicked, the category detail (a random joke) is displayed### How this App now your locally:
``Start graphql server(localhost:8000): npm run server ``
\
``Start client server(localhost:3000): npm run start```` To run both server and client server(localhost:3000): npn run dev ``
`` To run Test : npn run test``
#### App Demo:
[Chuck Norris App](https://frozen-thicket-53665.herokuapp.com)
### SandBox Project link:
[SandBox Profile link](https://codesandbox.io/u/MrBooi)
[SandBox link](https://lc3cq.sse.codesandbox.io/)