Graphql Parser doesn't handle comments?
It seems like graphql parser doesn't like graphql comments in the schemas? This is using the federated proxy example.
build base schema: parse graphql document string: external: unexpected token - got: COMMENT want one of: [], locations:
remote schema
input UserInput {
userID: Int
# Some comment
place: String
}
Hey, you're right. Comments are not supported. You can use descriptions instead, these work fine.
Is there no way to comment out graphql objects we've defined but don't want to be exposed because a description requires a key in the parser
This fails to parse because it needs a key. I feel like comments should just be ignored since they are supported still.
type User {
""" Username """
""" username: String! """
}
Is there no way to comment out graphql objects we've defined but don't want to be exposed because a description requires a key in the parser
This fails to parse because it needs a key. I feel like comments should just be ignored since they are supported still.
type User { """ Username """ """ username: String! """ }
I think it could help if you explain your use case a bit more. Filtering out fields from a schema is actually very trivial. This way, validation would fail if a client requests the field. That said, without further info on what you're trying to do I'm not sure I'm suggesting the right direction.