ToDo Application with GraphQL, Apollo, Prisma, HotChocolate, Entity Framework, React.js, Redux, and Apollo Client
This repository contains a ToDo application that demonstrates the usage of GraphQL servers implemented using Apollo and Prisma in Node.js, as well as HotChocolate and Entity Framework in .NET Core. The client is built using React.js, utilizing Redux for state management and Apollo Client for making GraphQL API calls.
- Create, read, update, and delete ToDo items.
- Real-time updates using GraphQL subscriptions.
- Server-side logic implemented using Apollo Server (Node.js) and HotChocolate (.NET Core).
- Persistent storage using Prisma (Node.js) and Entity Framework (.NET Core).
- Client-side state management using Redux.
- GraphQL API calls from the client using Apollo Client.
- Node.js and npm (for Node.js based server)
- .NET Core SDK (for .NET Core based server)
- Visual Studio Code or any preferred code editor
- Navigate to the
server-node
directory. - Install dependencies using
npm install
. - Configure your database connection in the
.env
file. - Run database migrations using
npx prisma migrate dev
. - Start the Apollo Server using
npm start
.
- Open the
server-dotnet
directory in Visual Studio or your preferred .NET Core IDE. - Configure your database connection in the
appsettings.json
file. - Build and run the .NET Core server.
- Navigate to the
client-react
directory. - Install dependencies using
npm install
. - Update the Apollo Client configuration in
src/apollo.js
to point to your server URLs. - Start the React development server using
npm start
.
- Open your browser and navigate to the React app (by default, it runs on http://localhost:3000).
- You'll see a list of ToDo items fetched from the GraphQL server.
- Use the UI to add, update, or delete ToDo items.
- Changes are updated in real-time thanks to GraphQL subscriptions.
server-node
: Node.js based GraphQL server with Apollo Server and Prisma.server-dotnet
: .NET Core based GraphQL server with HotChocolate and Entity Framework.client-react
: React.js based client with Redux for state management and Apollo Client for GraphQL API calls.
Contributions to this example application are welcome! Feel free to fork this repository, make improvements, and submit pull requests.
This project is licensed under the MIT License.
Feel free to modify and extend this README.md
as needed for your project. Make sure to adjust file paths, dependencies, and other details according to your project's structure and requirements.