Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/morellodev/fetalks-data-fetching
https://github.com/morellodev/fetalks-data-fetching
Last synced: 24 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/morellodev/fetalks-data-fetching
- Owner: morellodev
- Created: 2021-11-08T15:22:20.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2021-11-09T10:50:01.000Z (almost 3 years ago)
- Last Synced: 2024-05-01T16:19:57.434Z (6 months ago)
- Language: JavaScript
- Size: 1.24 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Users CRUD App
This is the demo app for the Front-End Talk about Data Fetching:
![Users App Screenshot](/docs/images/app-screenshot.png)
## Project Anatomy
This is a monorepo managed by Yarn Workspaces, containing 2 apps:
- Server – a Node.js app that provides the data
- Client – a Next.js app that consumes the data## Project Setup
Run `yarn` from the project root directory to install all dependencies.
### Server App
Run `yarn workspace @fetalks-data-fetching/server start` from the project root directory to start the server.
#### Customize the server
You can edit the `json-server.json` file inside the `packages/server` folder to customize the server. Refer to the [`json-server` documentation](https://github.com/typicode/json-server) for more information.
### Client App
Run `yarn workspace @fetalks-data-fetching/client dev` from the project root directory to start the client dev server.
#### Customize the API endpoint
To customize the endpoint of the server that provides the APIs used by the client app, create an `.env` file inside the `packages/client` folder containing the `NEXT_PUBLIC_JSON_SERVER_URL` environment variable with the desired URL.