Welcome to the gql-plants project, a GraphQL API that uses json-server as a database.
Make sure you have the following requirements installed before getting started:
- Node.js > 18: Download Node.js
- Yarn (an alternative package manager to npm): Install Yarn
Follow these steps to set up the project:
- Clone this repository:
git clone https://github.com/your-username/gql-plants.git
cd gql-plants
- Install project dependencies using Yarn:
yarn
- Start the GraphQL server and json-server:
yarn json-server
yarn dev
This will start the GraphQL server and json-server on their default ports: 4000 for GraphQL and 3001 for json-server.
- Access the GraphQL interface in your web browser:
Open your web browser and navigate to http://localhost:4000/graphql to access the GraphQL interface. From here, you can interact with the API and run queries and mutations.