Skip to content

joonlabs/php-graphql

Repository files navigation

index.js logo

php-graphql

CI Latest Stable Version License

php-graphql is a pure php implementation of the latest GraphQL specification based on the reference implementation in JavaScript.

Installation

Via composer:

composer require joonlabs/php-graphql

Via git submodule:

git clone https://github.com/joonlabs/php-graphql.git

For more information, see the doc pages

Documentation

The library's documentation is available at https://joonlabs.github.io/php-graphql/ or in the docs folder.

Examples

Examples can be found in the examples directory and are additionally discussed in the documentation.

Motivation

This project was developed out of internal needs in the company. We decided to go with an own implementation to stay in control of performance critical parts, implement cache systems and support file upload from scratch. Also this library does not use arrays but explicit parameters for initialization and configuration of types, fields and other objects. Thanks to features like named arguments which were added by PHP 8, this library achieves a high readability. As nice sideeffect this library seems to outperform the currently most used library webonyx/graphql-php in terms of speed in many use cases (please see https://github.com/joonlabs/graphql-benchmarks for reference).

Backers and sponsors

index.js logo
see joonlabs.com

index.js logo
see leafx.de

License

Fore more infromation regarding the license, see the LICENSE file.