https://github.com/devbigboy/laravel-graphql
https://github.com/devbigboy/laravel-graphql
graphql laravel mysql
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/devbigboy/laravel-graphql
- Owner: DevBigBoy
- Created: 2024-10-26T07:22:22.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-01T15:03:00.000Z (over 1 year ago)
- Last Synced: 2025-05-17T02:07:54.860Z (about 1 year ago)
- Topics: graphql, laravel, mysql
- Language: PHP
- Homepage:
- Size: 76.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Building GraphQL Applications in Laravel
## 🚀 Overview
GraphQL is a query language for APIs that enables application-to-application communication and provides a complete and understandable description of the data in your API, making it easier to evolve APIs over time. GraphQL lets you ask for what you want in a single query by enabling clients to request their own unique data specifications, saves bandwidth, and reduces waterfall requests. In this course, Rasheeda Yehuza shows you how to set up a GraphQL in Laravel (PHP) using Lighthouse to query data.
## Learning objectives
- Discover the benefits of GraphQL and learn why you might use it over REST.
- Review GraphQL use cases so you can better determine when to use GraphQL as your application interface.
- Learn about the most basic components of a GraphQL schema, including object types and fields, which provide a good grounding for all the other types in GraphQL.
- Review the most common object types of a GraphQL schema, including query and mutation types.
- Learn how to set up and bootstrap a new Laravel application.
- Discover how to connect to a database server, seed the built-in user tables, and connect the new Laravel application to access the database and tables.
- Learn how to set up and configure Lighthouse in a new Laravel application.
- Define queries in a GraphQL service and query a GraphQL application using an existing user database.
- Discover how to query a GraphQL API with arguments on an existing user's table and define the exact shape of data needed for specific arguments.
- Review how to use GraphQL mutations to create, update, and delete models using Lighthouse.
## 📸 Introduction to Graphal
-
## 🛠Installation
1. **Clone the Repository:**
```bash
git clone https://github.com/yourusername/your-repository.git
```
2. **Navigate to the Project Directory:**
```bash
cd your-repository
```
3. **Install Dependencies:**
```bash
composer install
npm install
```
4. **Set Up Environment File:**
Copy `.env.example` to `.env` and configure your database and other environment variables.
```bash
cp .env.example .env
```
5. **Generate Application Key:**
```bash
php artisan key:generate
```
6. **Run Migrations:**
```bash
php artisan migrate
```
7. **Start the Development Server:**
```bash
php artisan serve
```