Download the PHP package johnlui/graphql-laravel without Composer
On this page you can find all versions of the php package johnlui/graphql-laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download johnlui/graphql-laravel
More information about johnlui/graphql-laravel
Files in johnlui/graphql-laravel
Download johnlui/graphql-laravel
More information about johnlui/graphql-laravel
Files in johnlui/graphql-laravel
Vendor johnlui
Package graphql-laravel
Short Description A Laravel GraphQL reference implementation forked from webonyx/graphql-php
License MIT
Homepage https://github.com/johnlui/GraphQL-Laravel
Package graphql-laravel
Short Description A Laravel GraphQL reference implementation forked from webonyx/graphql-php
License MIT
Homepage https://github.com/johnlui/GraphQL-Laravel
Please rate this library. Is it a good library?
Informations about the package graphql-laravel
webonyx/graphql-php
的 Laravel 适配,魔改原库,将其彻底融入 Laravel 生命周期。
功能
- 接入 Laravel Middleware
- 依赖 Laravel Exception 处理异常流程
- 完美接入 Eloquent
- 提炼出 GraphQL 路由
- 提供 Types 文件夹,并提供强大的 Type 基类
- 提供 QueryFields 文件夹,提供类似于 Controller 归类的功能
- 暴露用户请求字段给 QueryField,便于节约资源、并发 RPC 等后续操作
- 提供 JSON API 语境下的调试函数
cc()
用法
安装 Composer 包
composer require johnlui/graphql-laravel
部署开发目录及配置文件到 app 下
php artisan vendor:publish
快速入门
app\GraphApp
为工作文件夹Routes.php
为路由文件QueryFields
目录存放响应代码Types
目录存放自定义类型config/graphql.php
为配置文件
demo
query:
variables:
此处为 JSON 格式描述,开发时应使用 key-value 形式描述 variables,不应该使用 JSON 字符串。
启动 server
php artisan serve
url
http://127.0.0.1:8000/graphql
修改默认路径请编辑config/graphql.php
中的apiUri
。
curl raw 代码描述
返回值
License
The johnlui/GraphQL-Laravel
is open-sourced software licensed under the MIT license
All versions of graphql-laravel with dependencies
PHP Build Version
Package Version
Requires
php Version
^7.1||^8.0
ext-json Version *
ext-mbstring Version *
ext-json Version *
ext-mbstring Version *
The package johnlui/graphql-laravel contains the following files
Loading the files please wait ....