Avris GraphqlBundle

Simplify Graphql configuration using plain methods with typehints and annotations.

This bundle is a wrapper on webonyx/graphql-php.

Disclaimer

I’m new to GraphQL, currently writing my first project using it.
I’m sure that many things are missing from the bundle and many assumptions I made are wrong,
so please be understanding, and if possible help out with a pull request.

The bundle will parse all the classes in src/Controller and src/Entity
(that list can be configured in the config key avris_graphql.load)
looking for the Graphql annotations.

All parameters of a query-method, as well as its return type have to be typehinted.
Supported built-in types are string, bool, int and float.
You can also typehint any type you registered with @Graphql\Type.

Additionally, you can use id, list (int[]) and union (int|float),
but for that you need an @Graph\ParamType or @Graph\ReturnType annotation for that.

Random post

Religious people often threaten atheists with what will happen to them after death, if they don’t convert. Yeah, cause out of all the different made-up stories about what happens after death, it’s specifically yours that’s gonna be the right one. Right...

Let’s revert that question into “what if you’re wasting your life on religious bullshit”. It’s not as scary, because if it’s the case, you won’t notice you were wrong (that’s how being dead works). Still, your current life is the only one that you know for sure you’re gonna get. Are you really willing to waste it?