Skip to content

Question: Extensibility of the lib #182

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
theobat opened this issue May 23, 2018 · 1 comment
Open

Question: Extensibility of the lib #182

theobat opened this issue May 23, 2018 · 1 comment
Labels

Comments

@theobat
Copy link
Contributor

theobat commented May 23, 2018

Hey, thanks a lot for this library, it's really good already.

Coming from JS land, I used a lib called join-monster which basically enables to map a graphql query (or a subset of it) to an SQL query, which I find extremely useful. The way this works is by enabling the parsed graphql query's AST to be "traversed" in the graphql query resolver to generate an sql query (by "assembling" pieces of sql text annotated in the schema).

I a not sure how to do this in haskell yet, but I don't think it could work with classic resolvers, because we need both the JSON-equivalent schema (that is the graphql schema) and its SQL counterpart.
I thought about creating functions mapping graphql types to beam (or any other sql-like lib) instances. But i'd still need to access the parsed query AST in the resolvers... If someone has any clue about this I'd be grateful ! (I'm reading the graphq-api Internals section but I'm new to haskell so, it's not so simple)

@jml jml added the question label May 25, 2018
@jml
Copy link
Collaborator

jml commented May 25, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants