We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7e8f975 commit 40e7b46Copy full SHA for 40e7b46
compiler/crates/graphql-ir/src/ir.rs
@@ -51,6 +51,13 @@ pub enum ExecutableDefinition {
51
}
52
53
impl ExecutableDefinition {
54
+ pub fn directives(&self) -> &[Directive] {
55
+ match self {
56
+ ExecutableDefinition::Operation(node) => &node.directives,
57
+ ExecutableDefinition::Fragment(node) => &node.directives,
58
+ }
59
60
+
61
pub fn has_directive(&self, directive_name: DirectiveName) -> bool {
62
match self {
63
ExecutableDefinition::Operation(node) => node
0 commit comments