Benedikt Franke

Results 536 comments of Benedikt Franke

Try running static analysis locally, see https://github.com/webonyx/graphql-php/blob/master/CONTRIBUTING.md#static-analysis

> Did you try series of parse and print to "normalize" the query string (with regards to whitespaces)? That would be a part of a proper tool for sure, but...

My instinct is to start out with fundamental building blocks, such as a function to serialize query strings into a normalized form. We might serialize the AST for quick rehydration.

What you are trying to do is quite tricky and requires deeply modifying the schema build process. Check out https://github.com/nuwave/lighthouse/tree/master/src/Schema for an example of how this can be achieved. This...

> If I may suggest something, it would be interesting to have a callback for enter/leave like Visitor already in buildSchema. Can you elaborate? What new use cases would this...

I think the purpose of the query plan is to allow the server to make decisions on how to resolve the query efficiently. Given aliases are given by the client...

Right, that is misleading. `args` should really be a list with multiple args passed to the different aliases - same with `fields` actually. Perhaps a better structure would be: ```json...

Can you do a minimal reproduction of this and do some actual measurements?

See https://github.com/graphql/graphql-js/pull/3362 for an attempt to get support into the reference implementation first. Let's see what they say before continuing here.

@vladar how about we just use public properties and prefix them all with `$message`: ```php class ValuesOfCorrectType extends ValidationRule { static public $messageUnknownField = 'Field "%s" is not defined by...