Skip to content
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

How to remove query from the output query ? #73

Open
revskill10 opened this issue Jul 22, 2019 · 1 comment
Open

How to remove query from the output query ? #73

revskill10 opened this issue Jul 22, 2019 · 1 comment

Comments

@revskill10
Copy link

revskill10 commented Jul 22, 2019

In my app, all of my graphql query is live query, so i have to skip query and subscription from the query itself.

That means, instead of using

query {
users {
id
}
}

i use

{
users {
id
}
}

This is, i think possible to skip the operation name query, mutation, subscription by adding an optional parameter, so that the output string query doesn't contain those names.

@acro5piano
Copy link
Owner

acro5piano commented Jul 22, 2019

Hi, thank you for your interest.

There are no options for unnamed query now. Any PRs are welcome!

Maybe if we just add a line here, the feature will be done:

export const query = createOperate('query')

Do you think which name is suitable for unnamed query?

import { ??? } from 'typed-graphqlify'
const someQuery = ???(''

live is too specific, so plain or query.plain or something?

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

No branches or pull requests

2 participants