What is AST in graphql ? I am using graphql-js. How does it help with anything?
Nothing in any documentation seems to explain what AST is
What is AST in graphql ? I am using graphql-js. How does it help with anything?
Nothing in any documentation seems to explain what AST is
GraphQL is two things:
When a GraphQL server receives a query to process it generally comes in as a single String. This string must be split into meaningful sub-strings (tokenization) and parsed into a representation that the machine understands. This representation is called an abstract syntax tree, or AST.
When GraphQL Processes the query, it walks the tree executing each part against the schema.
Converting raw strings to an AST is the first step of every compiler from C++ to Chrome's JavaScript's VM to Babel.
As for what GraphQL does and how it helps, here is a video that may explain it in a bit more detail. https://www.youtube.com/watch?v=PmWho45WmQY