You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current implementation of Schema always adds standard scalar types to the schema, even if they are not used. This differs from the reference implementation, which has added quite a few test cases that rely on missing standard scalars.
If a built-in scalar type is not referenced anywhere in a schema (there is no field, argument, or input field of that type) then it must not be included.
The text was updated successfully, but these errors were encountered:
Aligning the behaviour of this library exactly with graphql-js is difficult due to lazy loading. Given we don't want to eagerly traverse the schema and all its types, how can we differentiate if a standard scalar is supposed to be included in the schema when calling Schema::getType('Int')?
I think we should strive to align the behaviour with graphql-js if possible, but not at the cost of totally bombing performance. Due to the share-nothing request model of PHP, lazy type loading is very important.
The current implementation of
Schema
always adds standard scalar types to the schema, even if they are not used. This differs from the reference implementation, which has added quite a few test cases that rely on missing standard scalars.We should align our behaviour with the specification, see http://spec.graphql.org/draft/#sec-Scalars.Built-in-Scalars:
The text was updated successfully, but these errors were encountered: