├── .watchmanconfig ├── website ├── static │ ├── CNAME │ └── img │ │ ├── relay.png │ │ ├── favicon.ico │ │ ├── favicon.png │ │ ├── logos │ │ ├── up.png │ │ ├── rea.png │ │ ├── 1stdibs.png │ │ ├── artsy.png │ │ ├── bumped.png │ │ ├── cirrus.png │ │ ├── domonda.png │ │ ├── entria.png │ │ ├── foton.png │ │ ├── friday.png │ │ ├── kiwicom.png │ │ ├── oculus.png │ │ ├── parabol.png │ │ ├── quanto.png │ │ ├── autoguru.png │ │ ├── butterfly.png │ │ ├── clubhouse.png │ │ ├── facebook.png │ │ ├── flexport.png │ │ ├── itdagene.png │ │ ├── jusbrasil.png │ │ ├── m1finance.png │ │ ├── habilelabs.png │ │ ├── mindworking.png │ │ ├── lattice_logo_full_color.png │ │ └── swissdev-javascript-jobs.png │ │ ├── oss_logo.png │ │ ├── docs │ │ ├── mutations-view.png │ │ ├── store-explorer.png │ │ ├── editor-support │ │ │ ├── hover.png │ │ │ ├── deprecated.png │ │ │ ├── go-to-def.gif │ │ │ ├── autocomplete.png │ │ │ ├── code-actions.png │ │ │ └── diagnostics.png │ │ ├── entrypoints-devtools.png │ │ ├── entrypoints-devtools-2.png │ │ ├── entrypoints-devtools-3.png │ │ ├── mutations-view-updated.png │ │ ├── query-suspense-logger.png │ │ ├── store-explorer-updated.png │ │ ├── tutorial │ │ │ ├── preloaded-lazy.png │ │ │ ├── graphql-request.png │ │ │ ├── graphql-response.png │ │ │ ├── preloaded-basic.png │ │ │ ├── preloaded-ideal.png │ │ │ ├── query-breakdown.png │ │ │ ├── query-upon-graph.png │ │ │ ├── mutations-lifecycle.png │ │ │ ├── graphql-graph-detail.png │ │ │ ├── mutations-like-button.png │ │ │ ├── connections-edge-nodes.png │ │ │ ├── connections-full-model.png │ │ │ ├── fragment-newsfeed-story.png │ │ │ ├── fragment-reuse-combined.png │ │ │ ├── fragment-reuse-seperate.png │ │ │ ├── queries-basic-screenshot.png │ │ │ ├── arrays-top-stories-screenshot.png │ │ │ ├── connections-conceptual-graph.png │ │ │ ├── fragment-newsfeed-story-image.png │ │ │ ├── interfaces-person-screenshot.png │ │ │ ├── intro-screenshot-placeholder.png │ │ │ ├── refetchable-contacts-initial.png │ │ │ ├── refetchable-transition-search.png │ │ │ ├── arrays-keys-warning-screenshot.png │ │ │ ├── network-request-with-variables.png │ │ │ ├── queries-wrong-hovercard-person.png │ │ │ ├── refetchable-suspense-3-fallback.png │ │ │ ├── connections-full-model-next-page.png │ │ │ ├── fragment-image-add-once-compiled.png │ │ │ ├── fragment-newsfeed-story-combined.png │ │ │ ├── interfaces-organization-screenshot.png │ │ │ ├── query-variables-hovercard-correct.png │ │ │ ├── refetchable-suspense-1-data-needed.png │ │ │ ├── fragments-image-two-places-compiled.png │ │ │ ├── fragments-newsfeed-story-compilation.png │ │ │ ├── graphql-compiler-combines-fragments.png │ │ │ ├── graphql-relay-runtime-fetches-query.png │ │ │ ├── connections-comments-initial-screenshot.png │ │ │ ├── fragment-newsfeed-story-image-combined.png │ │ │ ├── mutations-comments-composer-screenshot.png │ │ │ └── refetechable-suspense-2-nearest-suspense-point.png │ │ ├── entrypoints-from-scratch.png │ │ ├── fragment-suspense-logger.png │ │ ├── Guides-Containers-HOC-Relay.png │ │ ├── entrypoints-ok-to-use-lazy.png │ │ ├── entrypoints-fetch-ahead-of-render.png │ │ ├── entrypoints-traditional-fetching.png │ │ ├── entrypoints-reusing-existing-infra.png │ │ ├── entrypoints-visual-migration-guide.png │ │ ├── entrypoints-converting-query-into-fragment.png │ │ ├── entrypoints-converting-query-into-fragment-2.png │ │ └── entrypoints-adding-query-to-existing-entrypoint.png │ │ └── ui │ │ ├── bg-graphql-section.png │ │ ├── bg-ahead-section-after.png │ │ └── bg-ahead-section-before.png ├── blog │ └── images │ │ ├── 2023-01-03-resilient-relay-apps-sections.png │ │ ├── 2023-01-03-resilient-relay-apps-asset-screen.png │ │ ├── 2023-01-03-resilient-relay-apps-empty-fallbacks.png │ │ ├── 2023-01-03-resilient-relay-apps-full-app-error.png │ │ ├── 2023-01-03-resilient-relay-apps-errors-everywhere.png │ │ ├── 2023-01-03-resilient-relay-apps-full-screen-error.png │ │ ├── 2023-01-03-resilient-relay-apps-missing-sparkline.png │ │ ├── 2021-12-08-introducing-the-new-relay-compiler-post-required.png │ │ └── 2021-12-08-introducing-the-new-relay-compiler-pre-required.png ├── docs │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md └── versioned_docs │ ├── version-v11.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v12.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v13.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v14.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v15.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v16.0.0 │ ├── api-reference │ │ └── types │ │ │ ├── Disposable.md │ │ │ └── UploadableMap.md │ └── guided-tour │ │ └── refetching │ │ └── OssAvoidSuspenseNote.md │ ├── version-v1.4.1 │ └── Modern-ConversionScripts.md │ ├── version-v1.5.0 │ └── Modern-ConversionScripts.md │ ├── version-v1.6.0 │ └── Modern-ConversionScripts.md │ ├── version-v1.6.1 │ └── Modern-ConversionScripts.md │ ├── version-v1.6.2 │ └── Modern-ConversionScripts.md │ ├── version-v1.7.0 │ └── Modern-ConversionScripts.md │ ├── version-v2.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v3.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v4.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v5.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v6.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v7.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v7.1.0 │ └── Modern-ConversionScripts.md │ ├── version-v8.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v9.0.0 │ └── Modern-ConversionScripts.md │ ├── version-v9.1.0 │ └── Modern-ConversionScripts.md │ ├── version-v10.0.0 │ └── Modern-ConversionScripts.md │ └── version-v10.0.1 │ └── Modern-ConversionScripts.md ├── compiler ├── .gitattributes ├── crates │ ├── fixture-tests │ │ └── tests │ │ │ └── uppercase │ │ │ └── fixtures │ │ │ ├── hello.txt │ │ │ ├── world.txt │ │ │ ├── hello.expected │ │ │ └── world.expected │ ├── docblock-syntax │ │ ├── tests │ │ │ └── parse │ │ │ │ └── fixtures │ │ │ │ ├── empty-block.ecmascript │ │ │ │ ├── docblock-ends-mid-line.ecmascript │ │ │ │ ├── simple_docblock.ecmascript │ │ │ │ ├── multiple-fields.ecmascript │ │ │ │ ├── invalid_docblock.invalid.ecmascript │ │ │ │ ├── invalid_field_name.invalid.ecmascript │ │ │ │ ├── missing_star.invalid.ecmascript │ │ │ │ ├── field-followed-by-free-text.ecmascript │ │ │ │ └── free-text-starting-with-star.ecmascript │ │ └── README.md │ ├── graphql-ir │ │ ├── README.md │ │ └── tests │ │ │ └── parse │ │ │ └── fixtures │ │ │ ├── simple-fragment.graphql │ │ │ ├── directive-generic.graphql │ │ │ ├── list-of-enums.graphql │ │ │ ├── simple-query.graphql │ │ │ ├── null-values.graphql │ │ │ ├── unknown-fragment-type.invalid.graphql │ │ │ ├── inline-untyped-fragment.graphql │ │ │ ├── unknown-fragment-type-suggestions.invalid.graphql │ │ │ ├── fetch_token_with_arguments.invalid.graphql │ │ │ ├── undefined-fragment.invalid.graphql │ │ │ ├── enum-values.graphql │ │ │ ├── field_argument_unknown.invalid.graphql │ │ │ ├── null-values.invalid.graphql │ │ │ ├── scalar-field-with-selection.graphql │ │ │ ├── duplicate_variables_invalid.graphql │ │ │ ├── fixme_fat_interface_on_union.graphql │ │ │ ├── linked-field-with-no-selection.invalid.graphql │ │ │ ├── object-argument.graphql │ │ │ ├── typename_with_arguments.invalid.graphql │ │ │ ├── literal-object-argument.graphql │ │ │ ├── undefined-type.invalid.graphql │ │ │ ├── fragment-with-argument-type.invalid.graphql │ │ │ ├── inline-fragment-on-wrong-type.invalid.graphql │ │ │ ├── inline-fragment-with-invalid-type.graphql │ │ │ ├── invalid-argument-type.invalid.graphql │ │ │ ├── list-argument.graphql │ │ │ ├── field_argument_wrong_type.invalid.graphql │ │ │ ├── directive-module-match-on-query.invalid.graphql │ │ │ ├── directive_wrong_argument_type.invalid.graphql │ │ │ ├── directive-unknown-argument.invalid.graphql │ │ │ ├── literal-list-argument.graphql │ │ │ ├── field_argument_missing_required.invalid.graphql │ │ │ ├── query-with-argument.invalid.graphql │ │ │ ├── scalar-handle-field.graphql │ │ │ ├── directive_missing_required_argument.invalid.graphql │ │ │ ├── fixme_fat_interface_on_union.invalid.graphql │ │ │ ├── duplicate_arguments.invalid.graphql │ │ │ ├── inline-fragment-within-wrong-parent-type.invalid.graphql │ │ │ ├── argument-complex-object.invalid.graphql │ │ │ ├── fragment-spread-on-wrong-type.invalid.graphql │ │ │ ├── list-argument-complex-object.graphql │ │ │ ├── complex-object-with-missing-fields.invalid.graphql │ │ │ ├── linked-handle-field-with-key.graphql │ │ │ ├── linked-handle-field.graphql │ │ │ ├── fragment-with-argument-type-syntax-error.invalid.graphql │ │ │ ├── argument_definitions.graphql │ │ │ ├── fragment-spread-within-wrong-parent-type.invalid.graphql │ │ │ ├── linked-handle-field-with-filters.graphql │ │ │ ├── linked-handle-filter.graphql │ │ │ ├── directive-include.graphql │ │ │ ├── field-arguments.graphql │ │ │ ├── fragment-with-both-variable-definition-and-directive.invalid.graphql │ │ │ ├── inline-fragment-within-invalid-inline-fragment-grandparent.invalid.graphql │ │ │ ├── inline-fragment-within-linked-field-and-wrong-inline-fragment.invalid.graphql │ │ │ ├── directive-module-on-field.invalid.graphql │ │ │ └── argument_definitions_directives_invalid_syntax.invalid.graphql │ ├── relay-lsp │ │ └── tests │ │ │ ├── hover │ │ │ └── fixtures │ │ │ │ ├── double_underscore_id_field.graphql │ │ │ │ ├── scalar_field_with_description.graphql │ │ │ │ ├── double_underscore_typename_field.graphql │ │ │ │ ├── whitespace_within_linked_field_selection.graphql │ │ │ │ ├── whitespace_after_query_selection.graphql │ │ │ │ ├── fragment_spread.graphql │ │ │ │ ├── fragment_definition_name.graphql │ │ │ │ └── scalar_field_from_client_schema_extension.graphql │ │ │ └── find_field_usages │ │ │ └── fixtures │ │ │ ├── query_field.graphql │ │ │ ├── find_supertype.graphql │ │ │ ├── fragment_field.graphql │ │ │ ├── fragment_field.nomatch.graphql │ │ │ ├── linked_field.graphql │ │ │ ├── find_subtype.graphql │ │ │ ├── linked_field.nomatch.graphql │ │ │ ├── inline_fragment.graphql │ │ │ ├── inline_fragment_also_matches_outer_type.graphql │ │ │ └── multiple_matches.graphql │ ├── relay-transforms │ │ └── tests │ │ │ ├── disallow_typename_on_root │ │ │ └── fixtures │ │ │ │ ├── valid.graphql │ │ │ │ ├── typename-on-mutation.invalid.graphql │ │ │ │ ├── typename-on-fragment.invalid.graphql │ │ │ │ ├── typename-on-query.invalid.graphql │ │ │ │ └── valid.expected │ │ │ ├── disallow_reserved_aliases │ │ │ └── fixtures │ │ │ │ ├── id-alias.graphql │ │ │ │ ├── relay_id-alias-with-errors.invalid.graphql │ │ │ │ └── id-alias.expected │ │ │ ├── assignable_directive │ │ │ └── fixtures │ │ │ │ ├── assignable-fragment.graphql │ │ │ │ ├── assignable-fragment-no-typename.invalid.graphql │ │ │ │ ├── assignable-fragment-other-fields.invalid.graphql │ │ │ │ ├── assignable-fragment-aliased-typename.invalid.graphql │ │ │ │ ├── assignable-fragment-directive-on-typename.invalid.graphql │ │ │ │ └── assignable-fragment-directive-other-directives.invalid.graphql │ │ │ ├── validate_relay_directives │ │ │ └── fixtures │ │ │ │ ├── plural-fragment.graphql │ │ │ │ ├── plural-fragment-variables.invalid.graphql │ │ │ │ ├── unmasked-spread.graphql │ │ │ │ └── unmasked-spread-with-directive.invalid.graphql │ │ │ ├── updatable_directive │ │ │ └── fixtures │ │ │ │ ├── updatable-fragment.graphql │ │ │ │ ├── skip.invalid.graphql │ │ │ │ ├── directive-query.invalid.graphql │ │ │ │ ├── include.invalid.graphql │ │ │ │ ├── required.invalid.graphql │ │ │ │ ├── client-side-updatable.graphql │ │ │ │ ├── directive-linked-field.invalid.graphql │ │ │ │ ├── directive-scalar-field.invalid.graphql │ │ │ │ ├── directive-inline-fragment.invalid.graphql │ │ │ │ ├── inline-fragment-interface-to-interface.invalid.graphql │ │ │ │ ├── doubly-nested-fragment-spread.invalid.graphql │ │ │ │ ├── non-assignable-fragment-spreads.invalid.graphql │ │ │ │ ├── directive-fragment-spread.invalid.graphql │ │ │ │ ├── type-narrowing.graphql │ │ │ │ └── resolver-scalar.invalid.graphql │ │ │ ├── required_directive │ │ │ └── fixtures │ │ │ │ ├── action-argument-omitted.invalid.graphql │ │ │ │ ├── scalar-field-log.graphql │ │ │ │ ├── scalar-field-no-log.graphql │ │ │ │ ├── scalar-field-throw.graphql │ │ │ │ ├── duplicate-field-ussage-alias.graphql │ │ │ │ ├── inline-directive.invalid.graphql │ │ │ │ ├── linked-field-log.graphql │ │ │ │ ├── linked-field-no-log.graphql │ │ │ │ ├── linked-field-throw.graphql │ │ │ │ ├── duplicate-field.invalid.graphql │ │ │ │ ├── inline-fragment-on-interface.invalid.graphql │ │ │ │ ├── multiple-required-fields.invalid.graphql │ │ │ │ ├── required-with-different-actions.invalid.graphql │ │ │ │ ├── inline-fragment-on-interface-within-linked-field.graphql │ │ │ │ ├── log-action-bubble-to-throw.invalid.graphql │ │ │ │ ├── none-action-bubble-to-log.invalid.graphql │ │ │ │ ├── none-action-bubble-to-throw.invalid.graphql │ │ │ │ ├── inline-fragment-on-union.invalid.graphql │ │ │ │ ├── duplicate-field-different-actions.invalid.graphql │ │ │ │ ├── inline-fragment-on-concrete-in-interface.invalid.graphql │ │ │ │ ├── conflicting-required-status-across-aliased-inline-fragments.graphql │ │ │ │ ├── inline-fragment-on-interface-with-linked-field.invalid.graphql │ │ │ │ ├── duplicate-field-include-directive.invalid.graphql │ │ │ │ ├── fragments-are-isolated.graphql │ │ │ │ ├── none-action-bubble-to-log-across-inline-fragment.invalid.graphql │ │ │ │ └── required-paths.graphql │ │ │ ├── fragment_alias_directive │ │ │ └── fixtures │ │ │ │ ├── default_alias_on_inline_fragment.graphql │ │ │ │ ├── default_alias_on_inline_fragment_without_type.invalid.graphql │ │ │ │ ├── aliased_inline_fragment.graphql │ │ │ │ ├── aliased_inline_fragment_without_type_condition.graphql │ │ │ │ ├── default_alias_on_fragment_spread.graphql │ │ │ │ └── alias_on_named_fragment.graphql │ │ │ ├── validate_module_names │ │ │ └── fixtures │ │ │ │ ├── FragmentWithInvalidName.invalid.graphql │ │ │ │ ├── QueryWithInvalidSuffix.invalid.graphql │ │ │ │ ├── QueryWithInvalidName.invalid.graphql │ │ │ │ ├── FragmentWithInvalidlyCapitalizedName.invalid.graphql │ │ │ │ ├── MutationWithInvalidSuffix.invalid.graphql │ │ │ │ ├── MutationWithInvalidName.invalid.graphql │ │ │ │ ├── SubscriptionWithInvalidSuffix.invalid.graphql │ │ │ │ ├── QueryWithValidName.graphql │ │ │ │ ├── SubscriptionWithInvalidName.invalid.graphql │ │ │ │ ├── FragmentWithValidName.graphql │ │ │ │ ├── fragment-with-valid-name.graphql │ │ │ │ ├── FragmentWithValidName.ios.graphql │ │ │ │ └── FragmentWithValidName.other-suffix.graphql │ │ │ ├── validate_no_double_underscore_alias │ │ │ └── fixtures │ │ │ │ ├── non_alias.graphql │ │ │ │ └── double_underscore.invalid.graphql │ │ │ ├── skip_client_extensions │ │ │ └── fixtures │ │ │ │ └── query-with-only-client-fields.graphql │ │ │ ├── match_transform │ │ │ └── fixtures │ │ │ │ ├── invalid-no-matches.graphql │ │ │ │ └── direct-js-field.invalid.graphql │ │ │ ├── defer_stream │ │ │ └── fixtures │ │ │ │ ├── stream.invalid.graphql │ │ │ │ ├── query-with-defer.graphql │ │ │ │ └── query-with-stream.graphql │ │ │ ├── relay_test_operation │ │ │ └── fixtures │ │ │ │ ├── prod_query.invalid.graphql │ │ │ │ ├── test_simple_query.graphql │ │ │ │ └── test_query_with_enums.graphql │ │ │ ├── skip_unused_variables │ │ │ └── fixtures │ │ │ │ └── non-nullable-variable-with-default.invalid.graphql │ │ │ ├── validate_required_arguments │ │ │ └── fixtures │ │ │ │ ├── argument-on-field.graphql │ │ │ │ ├── missing-argument-on-field.invalid.graphql │ │ │ │ └── missing-argument-on-directive.invalid.graphql │ │ │ ├── generate_id_field │ │ │ └── fixtures │ │ │ │ ├── abstract-plural.graphql │ │ │ │ ├── node-union.graphql │ │ │ │ └── non-node-union.graphql │ │ │ ├── declarative_connection │ │ │ └── fixtures │ │ │ │ ├── delete-from-store.graphql │ │ │ │ ├── delete-from-store-plural.graphql │ │ │ │ ├── delete-on-unspported-type.invalid.graphql │ │ │ │ ├── delete-edge-from-connection.graphql │ │ │ │ └── delete-edge-from-connection-plural.graphql │ │ │ ├── refetchable_fragment │ │ │ └── fixtures │ │ │ │ ├── fragment-on-interface-without-id.graphql │ │ │ │ ├── fragment-with-relay-plural.invalid.graphql │ │ │ │ ├── fragment-on-interface-which-implementations-not-implement-node.invalid.graphql │ │ │ │ └── fragment-on-node-with-id-argument-used.invalid.graphql │ │ │ ├── validate_deprecated_fields │ │ │ └── fixtures │ │ │ │ ├── deprecated_scalar_field.graphql │ │ │ │ ├── deprecated_directive_arg.graphql │ │ │ │ ├── deprecated_field_arg.graphql │ │ │ │ ├── deprecated_linked_field.graphql │ │ │ │ ├── deprecated_field_with_arguments.graphql │ │ │ │ ├── deprecated_field_with_reason.graphql │ │ │ │ ├── deprecated_directive_arg_with_reason.graphql │ │ │ │ ├── deprecated_field_arg_with_reason.graphql │ │ │ │ └── deprecated_scalar_field_within_linked_field.graphql │ │ │ ├── apply_fragment_arguments │ │ │ └── fixtures │ │ │ │ └── deletes-unreferenced-fragments.graphql │ │ │ ├── client_edges │ │ │ └── fixtures │ │ │ │ └── unexpected-waterfall.invalid.graphql │ │ │ ├── validate_static_args │ │ │ └── fixtures │ │ │ │ └── required-with-dynamic-arg.invalid.graphql │ │ │ ├── validate_unused_variables │ │ │ └── fixtures │ │ │ │ ├── query-with-unused-variable-error-suppressed.graphql │ │ │ │ └── query-with-invalid-error-suppression.graphql │ │ │ ├── assignable_fragment_spread │ │ │ └── fixtures │ │ │ │ ├── abstract-assignable-fragment-spread-on-concrete-type.graphql │ │ │ │ ├── assignable-fragment-spread-top-level.invalid.graphql │ │ │ │ ├── concrete-assignable-fragment-spread-on-matching-concrete-type.graphql │ │ │ │ ├── concrete-assignable-fragment-spread-on-abstract-type.graphql │ │ │ │ ├── abstract-assignable-fragment-spread-on-matching-abstract-type.graphql │ │ │ │ ├── abstract-assignable-fragment-spread-on-different-abstract-type.graphql │ │ │ │ ├── assignable-fragment-spread-with-directives.invalid.graphql │ │ │ │ ├── abstract-assignable-fragment-spread-on-concrete-type-in-updatable-fragment.graphql │ │ │ │ └── skipped-assignable-fragment-spread.invalid.graphql │ │ │ ├── updatable_fragment_spread │ │ │ └── fixtures │ │ │ │ ├── updatable_fragment_spread_abstract_in_concrete.graphql │ │ │ │ ├── updatable_fragment_spread_top_level.invalid.graphql │ │ │ │ ├── updatable_fragment_spread_abstract_in_same_abstract.graphql │ │ │ │ ├── updatable_fragment_spread_concrete_in_same_concrete.graphql │ │ │ │ ├── updatable_fragment_spread_in_condition.invalid.graphql │ │ │ │ ├── updatable_fragment_spread_concrete_in_different_concrete.invalid.graphql │ │ │ │ ├── updatable_fragment_spread_concrete_in_matching_abstract.invalid.graphql │ │ │ │ └── updatable_fragment_spread_concrete_in_non_matching_abstract.invalid.graphql │ │ │ ├── validate_global_variables │ │ │ └── fixtures │ │ │ │ ├── query-with-undefined-variable.invalid.graphql │ │ │ │ └── fragment-with-undefined-variable.invalid.graphql │ │ │ ├── disallow_non_node_id_fields │ │ │ └── fixtures │ │ │ │ ├── valid-id-selection.graphql │ │ │ │ └── illegal-scalar.invalid.graphql │ │ │ ├── skip_redundant_nodes │ │ │ └── fixtures │ │ │ │ └── dont-skip-different-ids.graphql │ │ │ ├── relay_resolvers │ │ │ └── fixtures │ │ │ │ └── missing-fragment-name.graphql │ │ │ ├── relay_actor_change │ │ │ └── fixtures │ │ │ │ ├── actor-change-no-viewer.invalid.graphql │ │ │ │ └── actor-change-pluarl.invalid.graphql │ │ │ ├── validate_connections │ │ │ └── fixtures │ │ │ │ └── connection-invalid-type.invalid.graphql │ │ │ ├── flatten │ │ │ └── fixtures │ │ │ │ └── flattens-inside-plural.graphql │ │ │ ├── subscription_transform │ │ │ └── fixtures │ │ │ │ └── subscription_transform_noop_no_spread.graphql │ │ │ └── provided_variable_fragment_transform │ │ │ └── fixtures │ │ │ └── single_fragment.graphql │ ├── graphql-syntax │ │ ├── tests │ │ │ ├── parse_executable_document │ │ │ │ └── fixtures │ │ │ │ │ ├── incomplete_field_alias.graphql │ │ │ │ │ ├── keyword_as_name.graphql │ │ │ │ │ ├── incorrect_variable_name.invalid.graphql │ │ │ │ │ ├── list_of_enum.graphql │ │ │ │ │ ├── fragment_with_variable_defs.invalid.graphql │ │ │ │ │ ├── invalid_number.graphql │ │ │ │ │ ├── spread_with_arguments.invalid.graphql │ │ │ │ │ ├── missing_zero_on_float.invalid.graphql │ │ │ │ │ ├── space_in_variable.graphql │ │ │ │ │ ├── unterminated_string.invalid.graphql │ │ │ │ │ └── multiple_parse_errors.invalid.graphql │ │ │ ├── parse_document_with_features │ │ │ │ └── fixtures │ │ │ │ │ ├── spread_with_arguments.graphql │ │ │ │ │ ├── fragment_with_variable_defs.graphql │ │ │ │ │ ├── fragment_with_empty_vardefs.invalid.graphql │ │ │ │ │ └── spread_with_empty_arguments.invalid.graphql │ │ │ ├── parse_executable_document_with_error_recovery │ │ │ │ └── fixtures │ │ │ │ │ ├── empty-argument-list.graphql │ │ │ │ │ ├── argument-name-only.graphql │ │ │ │ │ ├── argument-value-only.graphql │ │ │ │ │ ├── directive-without-name.graphql │ │ │ │ │ ├── argument-missing-value.graphql │ │ │ │ │ ├── empty-linked-field.graphql │ │ │ │ │ ├── argument-missing-identifier.graphql │ │ │ │ │ ├── argument-value-only-2.graphql │ │ │ │ │ ├── argument-missing-identifier-2.grahql │ │ │ │ │ ├── argument-value-only-3.grahql │ │ │ │ │ ├── inline-fragment-without-selection.graphql │ │ │ │ │ ├── argument-name-only-2.graphql │ │ │ │ │ ├── type-in-argument-value.graphql │ │ │ │ │ ├── argument-without-closing-paren.graphql │ │ │ │ │ ├── variable-definition-with-directive.graphql │ │ │ │ │ └── argument-missing-value-2.graphql │ │ │ ├── parse_schema_document │ │ │ │ └── fixtures │ │ │ │ │ ├── directive_description.graphql │ │ │ │ │ └── schema_with_leading_comment.graphql │ │ │ └── parse_document │ │ │ │ └── fixtures │ │ │ │ ├── invalid_definition.invalid.graphql │ │ │ │ └── mixed.graphql │ │ └── README.md │ ├── dependency-analyzer │ │ └── tests │ │ │ ├── ir │ │ │ └── fixtures │ │ │ │ ├── definitions-only-no-change.graphql │ │ │ │ ├── definitions-only-change-query.graphql │ │ │ │ ├── recursive-fragments.graphql │ │ │ │ └── definitions-only-no-change.expected │ │ │ └── ast │ │ │ └── fixtures │ │ │ └── definitions-only.graphql │ ├── relay-typegen │ │ └── tests │ │ │ ├── generate_flow │ │ │ └── fixtures │ │ │ │ ├── plural-fragment.graphql │ │ │ │ ├── required.graphql │ │ │ │ ├── updatable-operation.graphql │ │ │ │ ├── typename-in-union-with-other-fields.graphql │ │ │ │ ├── required-bubbles-to-fragment.graphql │ │ │ │ ├── required-throws-nested.graphql │ │ │ │ ├── simple.graphql │ │ │ │ ├── updatable-operation-plural-field-no-spreads.graphql │ │ │ │ ├── recursive-fragments.graphql │ │ │ │ ├── required-throw-doesnt-bubbles-to-fragment.graphql │ │ │ │ ├── required-throw-doesnt-bubbles-to-query.graphql │ │ │ │ ├── required-bubbles-to-non-null-linked-field.graphql │ │ │ │ ├── required-bubbles-to-non-null-plural-linked-field.graphql │ │ │ │ ├── required-bubbles-to-query.graphql │ │ │ │ ├── required-throws-within-non-null-linked-field.graphql │ │ │ │ ├── required-throws-within-non-null-plural-linked-field.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-fragment-root.graphql │ │ │ │ ├── required-bubbles-to-non-null-item-in-non-null-plural-linked-field.graphql │ │ │ │ ├── refetchable.graphql │ │ │ │ ├── required-bubbles-to-item-in-plural-field.graphql │ │ │ │ ├── required-raw-response-type.graphql │ │ │ │ ├── aliased-inline-fragment-spread.graphql │ │ │ │ ├── required-bubbles-to-item-in-required-plural-field.graphql │ │ │ │ ├── refetchable-fragment.graphql │ │ │ │ ├── required-bubbles-through-inline-fragments-to-fragment.graphql │ │ │ │ ├── conditional.graphql │ │ │ │ ├── required-bubbles-to-non-null-linked-field-through-inline-fragment.graphql │ │ │ │ ├── regular-query-with-assignable-fragment-spread.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-linked-field.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-query-root.graphql │ │ │ │ ├── required-bubbles-to-plural-fragment-root.graphql │ │ │ │ ├── required-within-aliased-inline-fragment.graphql │ │ │ │ ├── updatable-operation-plural-field-with-spreads.graphql │ │ │ │ ├── mutation-input-has-array.graphql │ │ │ │ ├── updatable-operation-assignable-fragment.graphql │ │ │ │ ├── required-chain-bubbles-to-non-null-linked-field-through-inline-fragment.graphql │ │ │ │ ├── required-within-aliased-inline-fragment-on-abstract.graphql │ │ │ │ ├── scalar-field.graphql │ │ │ │ ├── typename-on-union-with-non-matching-aliases.graphql │ │ │ │ ├── updatable-fragment-spread.graphql │ │ │ │ ├── aliased-fragment-spread.graphql │ │ │ │ ├── updatable-operation-special-fields.graphql │ │ │ │ ├── custom-scalar-type-import.graphql │ │ │ │ ├── actor-change.graphql │ │ │ │ └── required-bubbles-up-to-mutation-response.graphql │ │ │ ├── generate_typescript │ │ │ └── fixtures │ │ │ │ ├── plural-fragment.graphql │ │ │ │ ├── required.graphql │ │ │ │ ├── updatable-operation.graphql │ │ │ │ ├── typename-in-union-with-other-fields.graphql │ │ │ │ ├── required-bubbles-to-fragment.graphql │ │ │ │ ├── required-throws-nested.graphql │ │ │ │ ├── simple.graphql │ │ │ │ ├── updatable-operation-plural-field-no-spreads.graphql │ │ │ │ ├── recursive-fragments.graphql │ │ │ │ ├── required-throw-doesnt-bubbles-to-fragment.graphql │ │ │ │ ├── required-throw-doesnt-bubbles-to-query.graphql │ │ │ │ ├── required-bubbles-to-query.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-fragment-root.graphql │ │ │ │ ├── refetchable.graphql │ │ │ │ ├── aliased-inline-fragment-spread.graphql │ │ │ │ ├── required-bubbles-to-item-in-plural-field.graphql │ │ │ │ ├── required-raw-response-type.graphql │ │ │ │ ├── refetchable-fragment.graphql │ │ │ │ ├── conditional.graphql │ │ │ │ ├── required-bubbles-through-inline-fragments-to-fragment.graphql │ │ │ │ ├── regular-query-with-assignable-fragment-spread.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-linked-field.graphql │ │ │ │ ├── aliased-inline-fragment-spread-without-type-condition-query-root.graphql │ │ │ │ ├── required-within-aliased-inline-fragment.graphql │ │ │ │ ├── simple-use-import-type-syntax.graphql │ │ │ │ ├── mutation-input-has-array.graphql │ │ │ │ ├── updatable-operation-assignable-fragment.graphql │ │ │ │ ├── updatable-operation-plural-field-with-spreads.graphql │ │ │ │ ├── required-within-aliased-inline-fragment-on-abstract.graphql │ │ │ │ ├── scalar-field.graphql │ │ │ │ ├── typename-on-union-with-non-matching-aliases.graphql │ │ │ │ ├── aliased-fragment-spread.graphql │ │ │ │ ├── updatable-fragment-spread.graphql │ │ │ │ ├── updatable-operation-special-fields.graphql │ │ │ │ ├── custom-scalar-type-import.graphql │ │ │ │ └── required-bubbles-up-to-mutation-response.graphql │ │ │ └── generate_flow_with_custom_id │ │ │ └── fixtures │ │ │ └── simple.graphql │ ├── schema │ │ └── tests │ │ │ └── build_schema │ │ │ └── fixtures │ │ │ ├── invalid-type-reference.graphql │ │ │ ├── invalid-implements-non-interface.graphql │ │ │ ├── invalid-duplicate-directive.graphql │ │ │ ├── invalid-input-type-interface.graphql │ │ │ ├── invalid-interface-implements-noninterface.graphql │ │ │ ├── invalid-object-extension-duplicated-server-field.graphql │ │ │ ├── invalid-sdl.graphql │ │ │ ├── invalid-duplicate-query-operation.graphql │ │ │ ├── invalid-object-extension-local-duplicated-fields.graphql │ │ │ ├── invalid-input-type.graphql │ │ │ ├── invalid-input-type-union.graphql │ │ │ ├── directive-on-arg-def.graphql │ │ │ └── extend-interface-before-define.graphql │ ├── relay-codegen │ │ └── tests │ │ │ ├── request_metadata │ │ │ └── fixtures │ │ │ │ └── valid-documents.graphql │ │ │ ├── required_directive_codegen │ │ │ └── fixtures │ │ │ │ ├── required_directive.graphql │ │ │ │ └── required_linked_field.graphql │ │ │ └── aliased_fragments │ │ │ └── fixtures │ │ │ ├── aliased_inline_fragment_spread.graphql │ │ │ └── aliased_fragment_spread.graphql │ ├── relay-compiler │ │ └── tests │ │ │ ├── compile_relay_artifacts │ │ │ └── fixtures │ │ │ │ ├── plural-fragment.graphql │ │ │ │ ├── viewer-query.graphql │ │ │ │ ├── required-directive.graphql │ │ │ │ ├── complex-arguments.graphql │ │ │ │ ├── explicit-null-default-value.graphql │ │ │ │ ├── alias-same-as-name.graphql │ │ │ │ ├── duplicate_query_name.graphql │ │ │ │ ├── missing-argument-on-field.invalid.graphql │ │ │ │ ├── query-with-raw-response-type-directive.graphql │ │ │ │ ├── explicit-null-argument.graphql │ │ │ │ ├── selection_set_conflict_alias_covering_name.graphql │ │ │ │ ├── selection_set_conflict_different_name.graphql │ │ │ │ ├── scalar-handle-field.graphql │ │ │ │ ├── client-only-query.graphql │ │ │ │ ├── duplicate_fragment_name.graphql │ │ │ │ ├── client_fields_only_no_fragment_invalid.graphql │ │ │ │ ├── fragment-alias.graphql │ │ │ │ ├── unions.graphql │ │ │ │ ├── delete-edge.graphql │ │ │ │ ├── updatable-fragment-spread.graphql │ │ │ │ ├── delete-edge-plural.graphql │ │ │ │ ├── id-as-alias.invalid.graphql │ │ │ │ ├── fragment-alias-on-inline-fragment-does-not-get-flattened.graphql │ │ │ │ ├── selection_set_conflict_with_inline_fragment.graphql │ │ │ │ ├── linked-handle-field.graphql │ │ │ │ └── unused_fragment_argdef_invalid_suppression_arg.invalid.graphql │ │ │ └── compile_relay_artifacts_with_custom_id │ │ │ └── fixtures │ │ │ ├── viewer-query.graphql │ │ │ └── unions.graphql │ ├── graphql-text-printer │ │ └── tests │ │ │ ├── print_ast │ │ │ └── fixtures │ │ │ │ ├── string-enum-arg.invalid.graphql │ │ │ │ ├── empty_args.graphql │ │ │ │ ├── unknown-enum-arg.invalid.graphql │ │ │ │ ├── basic_var_defs_with_directives.graphql │ │ │ │ ├── single-value-array-of-objects.graphql │ │ │ │ ├── basic_arg_defs.graphql │ │ │ │ ├── basic_arg_defs_type.graphql │ │ │ │ ├── basic_query.graphql │ │ │ │ ├── basic_query_with_float.graphql │ │ │ │ ├── basic_fragment.graphql │ │ │ │ ├── lowercase-enum-fragment-arg.graphql │ │ │ │ └── string-enum-fragment-arg.graphql │ │ │ ├── print │ │ │ └── fixtures │ │ │ │ ├── empty_args.graphql │ │ │ │ ├── string-enum-arg.invalid.graphql │ │ │ │ ├── unknown-enum-arg.invalid.graphql │ │ │ │ ├── single-value-array-of-objects.graphql │ │ │ │ ├── basic_arg_defs.graphql │ │ │ │ ├── basic_query.graphql │ │ │ │ ├── basic_fragment.graphql │ │ │ │ ├── string-enum-fragment-arg.graphql │ │ │ │ ├── basic_inline_fragments.graphql │ │ │ │ └── fragment_variables.graphql │ │ │ ├── compact │ │ │ └── fixtures │ │ │ │ ├── empty_args.graphql │ │ │ │ ├── single-value-array-of-objects.graphql │ │ │ │ └── basic_query.graphql │ │ │ └── operation_printer │ │ │ └── fixtures │ │ │ └── field-arguments.graphql │ ├── extract-graphql │ │ └── tests │ │ │ └── extract │ │ │ └── fixtures │ │ │ └── simple.flow │ ├── graphql-ir-validations │ │ └── tests │ │ │ └── validate_selection_conflict │ │ │ └── fixtures │ │ │ ├── same-alias-on-different-types.graphql │ │ │ ├── same-alias-nested.graphql │ │ │ └── same-alias-under-different-inline-fragments.graphql │ ├── relay-docblock │ │ └── README.md │ └── errors │ │ └── src │ │ └── lib.rs ├── .cargo │ └── config.toml └── rustfmt.toml ├── packages ├── relay-runtime │ └── .gitignore ├── relay-test-utils-internal │ ├── schema-extensions │ │ ├── ClientObject.graphql │ │ ├── Bar.graphql │ │ ├── Feedback.graphql │ │ ├── Page.graphql │ │ ├── Settings.graphql │ │ ├── Actor.graphql │ │ ├── FriendsEdge.graphql │ │ ├── FriendsConnection.graphql │ │ ├── Foo.graphql │ │ └── Query.graphql │ └── README.md ├── relay-test-utils │ └── README.md ├── eslint-plugin-relay-internal │ └── README.md └── react-relay │ └── __tests__ │ └── __snapshots__ │ ├── ReactRelayFragmentContainer-test.js.snap │ ├── ReactRelayRefetchContainer-test.js.snap │ └── ReactRelayPaginationContainer-test.js.snap ├── vscode-extension ├── .prettierignore ├── .gitignore ├── .vscode │ └── settings.json ├── readme │ └── demo.gif ├── assets │ └── relay-logo-icon.png ├── .vscodeignore └── src │ └── constants.ts └── scripts └── .babelrc /.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} 2 | -------------------------------------------------------------------------------- /website/static/CNAME: -------------------------------------------------------------------------------- 1 | relay.dev -------------------------------------------------------------------------------- /compiler/.gitattributes: -------------------------------------------------------------------------------- 1 | * text eol=lf 2 | -------------------------------------------------------------------------------- /packages/relay-runtime/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules 2 | -------------------------------------------------------------------------------- /vscode-extension/.prettierignore: -------------------------------------------------------------------------------- 1 | out/** 2 | **.vsix 3 | -------------------------------------------------------------------------------- /scripts/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | "fbjs" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /vscode-extension/.gitignore: -------------------------------------------------------------------------------- 1 | out/ 2 | tsconfig.tsbuildinfo 3 | *.vsix 4 | -------------------------------------------------------------------------------- /compiler/crates/fixture-tests/tests/uppercase/fixtures/hello.txt: -------------------------------------------------------------------------------- 1 | Hello 2 | -------------------------------------------------------------------------------- /compiler/crates/fixture-tests/tests/uppercase/fixtures/world.txt: -------------------------------------------------------------------------------- 1 | world 2 | -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/empty-block.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | */ 3 | -------------------------------------------------------------------------------- /vscode-extension/.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "files.exclude": { 3 | "out": true 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/relay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/relay.png -------------------------------------------------------------------------------- /website/static/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/favicon.ico -------------------------------------------------------------------------------- /website/static/img/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/favicon.png -------------------------------------------------------------------------------- /website/static/img/logos/up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/up.png -------------------------------------------------------------------------------- /website/static/img/oss_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/oss_logo.png -------------------------------------------------------------------------------- /vscode-extension/readme/demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/vscode-extension/readme/demo.gif -------------------------------------------------------------------------------- /website/static/img/logos/rea.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/rea.png -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/docblock-ends-mid-line.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | * Hello World */ 3 | -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/simple_docblock.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | * Hello World 3 | */ 4 | -------------------------------------------------------------------------------- /website/static/img/logos/1stdibs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/1stdibs.png -------------------------------------------------------------------------------- /website/static/img/logos/artsy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/artsy.png -------------------------------------------------------------------------------- /website/static/img/logos/bumped.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/bumped.png -------------------------------------------------------------------------------- /website/static/img/logos/cirrus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/cirrus.png -------------------------------------------------------------------------------- /website/static/img/logos/domonda.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/domonda.png -------------------------------------------------------------------------------- /website/static/img/logos/entria.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/entria.png -------------------------------------------------------------------------------- /website/static/img/logos/foton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/foton.png -------------------------------------------------------------------------------- /website/static/img/logos/friday.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/friday.png -------------------------------------------------------------------------------- /website/static/img/logos/kiwicom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/kiwicom.png -------------------------------------------------------------------------------- /website/static/img/logos/oculus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/oculus.png -------------------------------------------------------------------------------- /website/static/img/logos/parabol.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/parabol.png -------------------------------------------------------------------------------- /website/static/img/logos/quanto.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/quanto.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/README.md: -------------------------------------------------------------------------------- 1 | # graphql_ir 2 | 3 | Strongly typed intermediate representation (IR) for GraphQL. 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/simple-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFragment on User { 2 | id 3 | } 4 | -------------------------------------------------------------------------------- /website/static/img/logos/autoguru.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/autoguru.png -------------------------------------------------------------------------------- /website/static/img/logos/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/butterfly.png -------------------------------------------------------------------------------- /website/static/img/logos/clubhouse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/clubhouse.png -------------------------------------------------------------------------------- /website/static/img/logos/facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/facebook.png -------------------------------------------------------------------------------- /website/static/img/logos/flexport.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/flexport.png -------------------------------------------------------------------------------- /website/static/img/logos/itdagene.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/itdagene.png -------------------------------------------------------------------------------- /website/static/img/logos/jusbrasil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/jusbrasil.png -------------------------------------------------------------------------------- /website/static/img/logos/m1finance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/m1finance.png -------------------------------------------------------------------------------- /website/static/img/logos/habilelabs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/habilelabs.png -------------------------------------------------------------------------------- /website/static/img/logos/mindworking.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/mindworking.png -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/ClientObject.graphql: -------------------------------------------------------------------------------- 1 | type ClientObject { 2 | description: String 3 | } 4 | -------------------------------------------------------------------------------- /vscode-extension/assets/relay-logo-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/vscode-extension/assets/relay-logo-icon.png -------------------------------------------------------------------------------- /website/static/img/docs/mutations-view.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/mutations-view.png -------------------------------------------------------------------------------- /website/static/img/docs/store-explorer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/store-explorer.png -------------------------------------------------------------------------------- /packages/relay-test-utils/README.md: -------------------------------------------------------------------------------- 1 | ## relay-test-utils 2 | 3 | More details: https://relay.dev/docs/guides/testing-relay-components/ 4 | -------------------------------------------------------------------------------- /vscode-extension/.vscodeignore: -------------------------------------------------------------------------------- 1 | .vscode/** 2 | src/** 3 | .gitignore 4 | **/tsconfig.json 5 | **/.eslintrc.json 6 | **/*.map 7 | **/*.ts -------------------------------------------------------------------------------- /website/static/img/ui/bg-graphql-section.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/ui/bg-graphql-section.png -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/multiple-fields.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | * @fieldOne Value1 3 | * @fieldTwo Value2 4 | */ 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/double_underscore_id_field.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | _|_id 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/scalar_field_with_description.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | na|me 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/hover.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-devtools.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-devtools.png -------------------------------------------------------------------------------- /website/static/img/ui/bg-ahead-section-after.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/ui/bg-ahead-section-after.png -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_typename_on_root/fixtures/valid.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | me { 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /packages/eslint-plugin-relay-internal/README.md: -------------------------------------------------------------------------------- 1 | # eslint-plugin-relay-internal 2 | 3 | ESLint rules intended to run on Relay's own codebase. 4 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/README.md: -------------------------------------------------------------------------------- 1 | ## relay-test-utils-internal 2 | 3 | A collection of internal helpers used for relay unit-tests. 4 | -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-devtools-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-devtools-2.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-devtools-3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-devtools-3.png -------------------------------------------------------------------------------- /website/static/img/docs/mutations-view-updated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/mutations-view-updated.png -------------------------------------------------------------------------------- /website/static/img/docs/query-suspense-logger.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/query-suspense-logger.png -------------------------------------------------------------------------------- /website/static/img/docs/store-explorer-updated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/store-explorer-updated.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/preloaded-lazy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/preloaded-lazy.png -------------------------------------------------------------------------------- /website/static/img/ui/bg-ahead-section-before.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/ui/bg-ahead-section-before.png -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/invalid_docblock.invalid.ecmascript: -------------------------------------------------------------------------------- 1 | /* 2 | // Can't parse this! 3 | // expected-to-throw 4 | */ 5 | -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/invalid_field_name.invalid.ecmascript: -------------------------------------------------------------------------------- 1 | /* 2 | * @# Not allowed 3 | * expected-to-throw 4 | */ 5 | -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/missing_star.invalid.ecmascript: -------------------------------------------------------------------------------- 1 | /* 2 | * @fieldName field value 3 | expected-to-throw 4 | */ 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive-generic.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFragment on User { 2 | id @customDirective(level: 11) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/list-of-enums.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFragment on User { 2 | traits # This is a list of enums. 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/simple-query.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery($id: ID!) { 2 | foo: node(id: $id) { 3 | id 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/incomplete_field_alias.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | { 3 | foo: 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/double_underscore_typename_field.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | _|_typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/deprecated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/deprecated.png -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/go-to-def.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/go-to-def.gif -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-from-scratch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-from-scratch.png -------------------------------------------------------------------------------- /website/static/img/docs/fragment-suspense-logger.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/fragment-suspense-logger.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/graphql-request.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/graphql-request.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/graphql-response.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/graphql-response.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/preloaded-basic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/preloaded-basic.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/preloaded-ideal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/preloaded-ideal.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/query-breakdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/query-breakdown.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/query-upon-graph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/query-upon-graph.png -------------------------------------------------------------------------------- /website/static/img/logos/lattice_logo_full_color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/lattice_logo_full_color.png -------------------------------------------------------------------------------- /website/static/img/logos/swissdev-javascript-jobs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/logos/swissdev-javascript-jobs.png -------------------------------------------------------------------------------- /compiler/crates/dependency-analyzer/tests/ir/fixtures/definitions-only-no-change.graphql: -------------------------------------------------------------------------------- 1 | # 2 | query Q1 { 3 | me { 4 | id 5 | name 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/null-values.graphql: -------------------------------------------------------------------------------- 1 | query NullValuesQuery { 2 | items(filter: {date: null}) { 3 | date 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/unknown-fragment-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on UnknownType { 3 | id 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document_with_features/fixtures/spread_with_arguments.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | ...Bar(x: $x) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/query_field.graphql: -------------------------------------------------------------------------------- 1 | query Q { 2 | __typename 3 | } 4 | 5 | %arguments% 6 | Query __typename 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/whitespace_within_linked_field_selection.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { | 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/plural-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment PluralFragment on Node @relay(plural: true) { 2 | id 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-type-reference.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | emails: [Email!]! 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/Guides-Containers-HOC-Relay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/Guides-Containers-HOC-Relay.png -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/autocomplete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/autocomplete.png -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/code-actions.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/code-actions.png -------------------------------------------------------------------------------- /website/static/img/docs/editor-support/diagnostics.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/editor-support/diagnostics.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-ok-to-use-lazy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-ok-to-use-lazy.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/mutations-lifecycle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/mutations-lifecycle.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-untyped-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment InlineUntypedFragment on User { 2 | ... { 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/keyword_as_name.graphql: -------------------------------------------------------------------------------- 1 | query KeywordAsName { 2 | search_results(query: "test") 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_reserved_aliases/fixtures/id-alias.graphql: -------------------------------------------------------------------------------- 1 | fragment User_fragment on User { 2 | id: id 3 | __typename 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/plural-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment PluralFragment on Node @relay(plural: true) { 2 | id 3 | } 4 | -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/graphql-graph-detail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/graphql-graph-detail.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/mutations-like-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/mutations-like-button.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/unknown-fragment-type-suggestions.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Users { 3 | id 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/empty-argument-list.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo() 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_schema_document/fixtures/directive_description.graphql: -------------------------------------------------------------------------------- 1 | """ 2 | My Directive 3 | """ 4 | directive @my_directive on FIELD 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-codegen/tests/request_metadata/fixtures/valid-documents.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithMetadata { 2 | node(id: "foo") { 3 | id 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-fetch-ahead-of-render.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-fetch-ahead-of-render.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-traditional-fetching.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-traditional-fetching.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/connections-edge-nodes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/connections-edge-nodes.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/connections-full-model.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/connections-full-model.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-newsfeed-story.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-newsfeed-story.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-reuse-combined.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-reuse-combined.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-reuse-seperate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-reuse-seperate.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/queries-basic-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/queries-basic-screenshot.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fetch_token_with_arguments.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on User { 3 | __token(arg: 1) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/undefined-fragment.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on User { 3 | ...SomeUndefinedFragment 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document_with_features/fixtures/fragment_with_variable_defs.graphql: -------------------------------------------------------------------------------- 1 | fragment Test($x: Int = 3) on User { 2 | ...Bar 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/incorrect_variable_name.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | { 3 | image(size: $100) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/list_of_enum.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFrag on MyType { 2 | issues(orderby: [LAST_UPDATED]) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-name-only.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(size) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-value-only.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo($size) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/directive-without-name.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo @ 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/whitespace_after_query_selection.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query MyQuery { 3 | me { 4 | name 5 | } 6 | } | 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment AssignableFragment on Page @assignable { 2 | __typename 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_relay_directives/fixtures/plural-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment PluralFragment on User @relay(plural: true) { 2 | name 3 | } 4 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Bar.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | type Bar { 4 | content: String 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-reusing-existing-infra.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-reusing-existing-infra.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-visual-migration-guide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-visual-migration-guide.png -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-missing-value.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(size:) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/empty-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | user { 3 | } 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/updatable-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment UpdatableFragment_page on Page @updatable { 2 | __typename 3 | } 4 | -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-sections.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-sections.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/arrays-top-stories-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/arrays-top-stories-screenshot.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/connections-conceptual-graph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/connections-conceptual-graph.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-newsfeed-story-image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-newsfeed-story-image.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/interfaces-person-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/interfaces-person-screenshot.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/intro-screenshot-placeholder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/intro-screenshot-placeholder.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/refetchable-contacts-initial.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/refetchable-contacts-initial.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/refetchable-transition-search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/refetchable-transition-search.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/enum-values.graphql: -------------------------------------------------------------------------------- 1 | query EnumValueQuery { 2 | me { 3 | profilePicture(preset: LARGE) { 4 | uri 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-missing-identifier.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(: $size) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-value-only-2.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(s: 42, $size) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-codegen/tests/required_directive_codegen/fixtures/required_directive.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment on Node { 2 | id 3 | name @required(action: LOG) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/find_supertype.graphql: -------------------------------------------------------------------------------- 1 | fragment TestLinkedFieldFragment on User { 2 | name 3 | } 4 | 5 | %arguments% 6 | Actor name 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/fragment_field.graphql: -------------------------------------------------------------------------------- 1 | fragment TestLinkedFieldFragment on User { 2 | name 3 | } 4 | 5 | %arguments% 6 | User name 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me { 3 | firstName 4 | lastName @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-operation.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | me { 3 | actorCount 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-asset-screen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-asset-screen.png -------------------------------------------------------------------------------- /website/docs/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/arrays-keys-warning-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/arrays-keys-warning-screenshot.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/network-request-with-variables.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/network-request-with-variables.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/queries-wrong-hovercard-person.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/queries-wrong-hovercard-person.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/refetchable-suspense-3-fallback.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/refetchable-suspense-3-fallback.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/field_argument_unknown.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | task(cucumber: 123) { 4 | title 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/null-values.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query NullValuesQuery { 3 | node_id_required(id: null) { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/scalar-field-with-selection.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment ScalarHandleField on User { 3 | name { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document/fixtures/invalid_definition.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment F on User { 4 | __typename 5 | } 6 | 7 | foobar 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/plural-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment pluralFragment_PluralFragment on User @relay(plural: true) { 2 | name 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/viewer-query.graphql: -------------------------------------------------------------------------------- 1 | query viewerQueryQuery { 2 | viewer { 3 | actor { 4 | id 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_typename_on_root/fixtures/typename-on-mutation.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | mutation TestMutation { 3 | __typename 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/typename-in-union-with-other-fields.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | id 3 | ... on User { 4 | __typename 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me { 3 | firstName 4 | lastName @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-operation.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | me { 3 | actorCount 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-empty-fallbacks.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-empty-fallbacks.png -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-full-app-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-full-app-error.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-converting-query-into-fragment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-converting-query-into-fragment.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/connections-full-model-next-page.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/connections-full-model-next-page.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-image-add-once-compiled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-image-add-once-compiled.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-newsfeed-story-combined.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-newsfeed-story-combined.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/interfaces-organization-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/interfaces-organization-screenshot.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/query-variables-hovercard-correct.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/query-variables-hovercard-correct.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/refetchable-suspense-1-data-needed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/refetchable-suspense-1-data-needed.png -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/duplicate_variables_invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query Test($id: ID!, $id: ID) { 3 | user(id: $id) { 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fixme_fat_interface_on_union.graphql: -------------------------------------------------------------------------------- 1 | query Test { 2 | # this is a union 3 | maybeNode { 4 | id @fixme_fat_interface 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/linked-field-with-no-selection.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment LinkedHandleField on User { 3 | friends(first: 10) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/object-argument.graphql: -------------------------------------------------------------------------------- 1 | query ObjectArgument($text: String!) { 2 | checkinSearchQuery(query: {query: $text}) { 3 | query 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/typename_with_arguments.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment TypenameWithArguments on User { 4 | __typename(arg: 1) 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document_with_features/fixtures/fragment_with_empty_vardefs.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Test() on User { 3 | ...Bar 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document_with_features/fixtures/spread_with_empty_arguments.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Test on User { 3 | ...Bar() 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-missing-identifier-2.grahql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(s: 42, : $size) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-value-only-3.grahql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(h: 42, 12, scale: 2.0) 3 | } 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/action-argument-omitted.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | name @required 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/scalar-field-log.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on Node { 2 | id 3 | name @required(action: LOG) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/typename-in-union-with-other-fields.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | id 3 | ... on User { 4 | __typename 5 | } 6 | } -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Feedback.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type Feedback { 4 | isSavingLike: Boolean 5 | } 6 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Page.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type Page { 4 | client_actor_field: String 5 | } 6 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Settings.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type Settings { 4 | client_field: String 5 | } 6 | -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-errors-everywhere.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-errors-everywhere.png -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-full-screen-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-full-screen-error.png -------------------------------------------------------------------------------- /website/blog/images/2023-01-03-resilient-relay-apps-missing-sparkline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2023-01-03-resilient-relay-apps-missing-sparkline.png -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-converting-query-into-fragment-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-converting-query-into-fragment-2.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragments-image-two-places-compiled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragments-image-two-places-compiled.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragments-newsfeed-story-compilation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragments-newsfeed-story-compilation.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/graphql-compiler-combines-fragments.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/graphql-compiler-combines-fragments.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/graphql-relay-runtime-fetches-query.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/graphql-relay-runtime-fetches-query.png -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/field-followed-by-free-text.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | * @fieldName 3 | * This text is free text, not connected to the above boolean field 4 | */ 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/literal-object-argument.graphql: -------------------------------------------------------------------------------- 1 | query LiteralObjectArgument { 2 | checkinSearchQuery(query: {query: "Facebook"}) { 3 | query 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/undefined-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery($id: UnknownType) { 3 | node(id: "someid") { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/required-directive.graphql: -------------------------------------------------------------------------------- 1 | fragment requiredDirective_Foo_user on User { 2 | id 3 | name @required(action: THROW) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/fragment_spread.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | ...MyFrag|ment 4 | } 5 | } 6 | 7 | fragment MyFragment on User { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_typename_on_root/fixtures/typename-on-fragment.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment TestFragment on Query { 3 | __typename 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/default_alias_on_inline_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | ... on User @alias { 3 | name 4 | } 5 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/scalar-field-no-log.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on Node { 2 | id 3 | name @required(action: NONE) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/scalar-field-throw.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on Node { 2 | id 3 | name @required(action: THROW) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/FragmentWithInvalidName.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | fragment AnyOtherNameIsInvalid on User { 3 | name 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/QueryWithInvalidSuffix.invalid.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithInvalidSuffixMutation { 2 | me { 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | lastName @required(action: NONE) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-throws-nested.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me { 3 | firstName 4 | lastName @required(action: THROW) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/simple.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedField on User { 2 | name 3 | profilePicture { 4 | uri 5 | width 6 | height 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Actor.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend interface Actor { 4 | client_actor_field: String 5 | } 6 | -------------------------------------------------------------------------------- /website/static/img/docs/entrypoints-adding-query-to-existing-entrypoint.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/entrypoints-adding-query-to-existing-entrypoint.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/connections-comments-initial-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/connections-comments-initial-screenshot.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/fragment-newsfeed-story-image-combined.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/fragment-newsfeed-story-image-combined.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/mutations-comments-composer-screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/mutations-comments-composer-screenshot.png -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/tests/parse/fixtures/free-text-starting-with-star.ecmascript: -------------------------------------------------------------------------------- 1 | /** 2 | * Free text might use markdown because: 3 | * * It's neat 4 | * * It's conventional 5 | */ 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fragment-with-argument-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on User @argumentDefinitions(user: {type: "User!"}) { 3 | id 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-fragment-on-wrong-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment InlineFragment on Node { 3 | ... on Image { 4 | url 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/fragment_with_variable_defs.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Test($x: Int = 3) on User { 3 | ...Bar 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/invalid_number.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | friends(first: 1.23.4) { 4 | count 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/spread_with_arguments.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Test on User { 3 | ...Bar(x: $x) 4 | ...Foo() 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/inline-fragment-without-selection.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | ... on User 3 | username 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/string-enum-arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User { 2 | checkins(environments: "WEB") { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-codegen/tests/required_directive_codegen/fixtures/required_linked_field.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment on User { 2 | address @required(action: LOG) { 3 | city 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/fragment_field.nomatch.graphql: -------------------------------------------------------------------------------- 1 | fragment TestLinkedFieldFragment on User { 2 | name 3 | } 4 | 5 | %arguments% 6 | MaybeNodeInterface name 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/skip.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) @skip(if: true) { 4 | id 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_no_double_underscore_alias/fixtures/non_alias.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery($Id: ID!) { 2 | node(id: $Id) { 3 | __id 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-operation-plural-field-no-spreads.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | nodes(ids: [4]) { 3 | id 4 | } 5 | } 6 | 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-bubbles-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | lastName @required(action: NONE) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-throws-nested.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me { 3 | firstName 4 | lastName @required(action: THROW) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/simple.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedField on User { 2 | name 3 | profilePicture { 4 | uri 5 | width 6 | height 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-fragment-with-invalid-type.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment InlineFragment on Node { 3 | ... on UnkwnownType { 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/invalid-argument-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query InvalidQueryArgument($user: User!) { 3 | node(id: $user) { 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/list-argument.graphql: -------------------------------------------------------------------------------- 1 | query ListArgumentQuery { 2 | route(waypoints: [{lat: "0.0", lon: "0.0"}]) { 3 | steps { 4 | note 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-name-only-2.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo( 3 | s 4 | size: $size 5 | ) 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/type-in-argument-value.graphql: -------------------------------------------------------------------------------- 1 | query Test @test(: ID!) { 2 | node { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/fragment_definition_name.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | ...MyFragment 4 | } 5 | } 6 | 7 | fragment MyFra|gment on User { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_typename_on_root/fixtures/typename-on-query.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | __typename 4 | me { 5 | name 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/directive-query.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable @live_query { 3 | node(id: 4) { 4 | id 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/include.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) @include(if: true) { 4 | id 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-operation-plural-field-no-spreads.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | nodes(ids: [4]) { 3 | id 4 | } 5 | } 6 | 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v11.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v12.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v13.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v14.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v15.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v16.0.0/api-reference/types/Disposable.md: -------------------------------------------------------------------------------- 1 | #### Interface `Disposable` 2 | 3 | * An object with the following key: 4 | * `dispose`: `() => void`. Disposes of the resource. 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/field_argument_wrong_type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | task(number: 9.75) { # should be an Int 4 | title 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-without-closing-paren.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo (size: $size { 3 | url 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/empty_args.graphql: -------------------------------------------------------------------------------- 1 | query EmptyArgs { 2 | route(waypoints: []) { 3 | __typename 4 | } 5 | items(filter: {}) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/complex-arguments.graphql: -------------------------------------------------------------------------------- 1 | query complexArguments_TestQuery($date: String) { 2 | items(filter: {date: $date}) { 3 | date 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts_with_custom_id/fixtures/viewer-query.graphql: -------------------------------------------------------------------------------- 1 | query viewerQueryQuery { 2 | viewer { 3 | actor { 4 | global_id 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment-no-typename.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment AssignableFragment on Page @assignable { 3 | id 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/skip_client_extensions/fixtures/query-with-only-client-fields.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | foo 3 | } 4 | 5 | # %extensions% 6 | extend type Query { 7 | foo: String 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/QueryWithInvalidName.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | query QueryWithAnotherNameQuery { 3 | me { 4 | name 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/recursive-fragments.graphql: -------------------------------------------------------------------------------- 1 | fragment FragmentSpread on Node { 2 | id 3 | ... @include(if: $condition) { 4 | ...FragmentSpread 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-throw-doesnt-bubbles-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | lastName @required(action: THROW) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-throw-doesnt-bubbles-to-query.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me @required(action: THROW) { 3 | firstName 4 | lastName 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/FriendsEdge.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type FriendsEdge { 4 | client_friend_edge_field: String 5 | } 6 | -------------------------------------------------------------------------------- /website/blog/images/2021-12-08-introducing-the-new-relay-compiler-post-required.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2021-12-08-introducing-the-new-relay-compiler-post-required.png -------------------------------------------------------------------------------- /website/blog/images/2021-12-08-introducing-the-new-relay-compiler-pre-required.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/blog/images/2021-12-08-introducing-the-new-relay-compiler-pre-required.png -------------------------------------------------------------------------------- /website/static/img/docs/tutorial/refetechable-suspense-2-nearest-suspense-point.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sync/relay/main/website/static/img/docs/tutorial/refetechable-suspense-2-nearest-suspense-point.png -------------------------------------------------------------------------------- /compiler/.cargo/config.toml: -------------------------------------------------------------------------------- 1 | # This file should be kept in sync with the project's Buck flags. 2 | # See parent PACKAGE. 3 | 4 | [build] 5 | rustflags = [ 6 | "-Drust-2018-idioms", 7 | "-Dwarnings", 8 | ] 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive-module-match-on-query.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery($id: ID!) @module @match { 3 | foo: node(id: $id) { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive_wrong_argument_type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | me { 4 | name @customDirective(level: "not an Int!") 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/compact/fixtures/empty_args.graphql: -------------------------------------------------------------------------------- 1 | query EmptyArgs { 2 | route(waypoints: []) { 3 | __typename 4 | } 5 | items(filter: {}) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/empty_args.graphql: -------------------------------------------------------------------------------- 1 | query EmptyArgs { 2 | route(waypoints: []) { 3 | __typename 4 | } 5 | items(filter: {}) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/unknown-enum-arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User { 2 | checkins(environments: UNKNOWN_ENUM_VALUE) { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/required.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query requiredQuery @updatable { 3 | me { 4 | name @required(action: NONE) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_relay_directives/fixtures/plural-fragment-variables.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment PluralFragment on User @relay(plural: $plural) { 3 | name 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/recursive-fragments.graphql: -------------------------------------------------------------------------------- 1 | fragment FragmentSpread on Node { 2 | id 3 | ... @include(if: $condition) { 4 | ...FragmentSpread 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-throw-doesnt-bubbles-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | lastName @required(action: THROW) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-throw-doesnt-bubbles-to-query.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me @required(action: THROW) { 3 | firstName 4 | lastName 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive-unknown-argument.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | task(number: 123) { 4 | title @include(if: false, bif: true) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/literal-list-argument.graphql: -------------------------------------------------------------------------------- 1 | query LiteralListArgumentQuery { 2 | route(waypoints: [{lat: "0.0", lon: "0.0"}]) { 3 | steps { 4 | note 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/missing_zero_on_float.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | { 3 | friends( 4 | arg: .5 5 | ) { 6 | count 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/string-enum-arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment UserFragment on User { 3 | checkins(environments: "WEB") { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/explicit-null-default-value.graphql: -------------------------------------------------------------------------------- 1 | query explicitNullDefaultValue_TestQuery($id: ID = null) { 2 | node(id: $id) { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/linked_field.graphql: -------------------------------------------------------------------------------- 1 | fragment TestLinkedFieldFragment on Query { 2 | me { # User type 3 | name 4 | } 5 | } 6 | 7 | %arguments% 8 | User name 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/duplicate-field-ussage-alias.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledFoo on User { 2 | name @required(action: THROW) 3 | my_name: name @required(action: LOG) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-directive.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFragment on Node @inline { 3 | id 4 | name @required(action: LOG) 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-non-null-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | nearest_neighbor { 3 | name @required(action: LOG) 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-non-null-plural-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | neighbors { 3 | name @required(action: LOG) 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-query.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me @required(action: LOG) { 3 | firstName 4 | lastName @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-implements-non-interface.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | id: ID 5 | } 6 | 7 | type Page implements User { 8 | id: ID 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/field_argument_missing_required.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | username { # missing required `name` argument 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/query-with-argument.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @argumentDefinitions(id: {type: "ID!"}) { 3 | task(number: 123) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/scalar-handle-field.graphql: -------------------------------------------------------------------------------- 1 | fragment ScalarHandleField on User { 2 | name 3 | @__clientField(handle: "clientName") 4 | @__clientField(handle: "clientName2") 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/variable-definition-with-directive.graphql: -------------------------------------------------------------------------------- 1 | mutation Mutation( 2 | $variable: ID = null @some_directive 3 | ) { 4 | field 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/alias-same-as-name.graphql: -------------------------------------------------------------------------------- 1 | query aliasSameAsName_TestQuery { 2 | viewer: viewer { 3 | actor: actor { 4 | name: name 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment-other-fields.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment AssignableFragment on Page @assignable { 3 | id 4 | __typename 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/match_transform/fixtures/invalid-no-matches.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment NameRendererFragment on User { 3 | id 4 | nameRenderer @match { 5 | __typename 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/linked-field-log.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on User { 2 | id 3 | profile_picture @required(action: LOG) { 4 | uri 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/FragmentWithInvalidlyCapitalizedName.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | fragment fragmentWithInvalidlyCapitalizedName on User { 3 | name 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-throws-within-non-null-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | nearest_neighbor { 3 | name @required(action: THROW) 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-throws-within-non-null-plural-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | neighbors { 3 | name @required(action: THROW) 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-bubbles-to-query.graphql: -------------------------------------------------------------------------------- 1 | query FooQuery { 2 | me @required(action: LOG) { 3 | firstName 4 | lastName @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-duplicate-directive.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | directive @fetchable(field_name: String) on OBJECT 4 | directive @fetchable(field_name: String) on OBJECT 5 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/FriendsConnection.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type FriendsConnection { 4 | client_friends_connection_field: String 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_document/fixtures/mixed.graphql: -------------------------------------------------------------------------------- 1 | scalar Foo 2 | 3 | """ 4 | Definition with comment 5 | """ 6 | type User { 7 | id: ID! 8 | } 9 | 10 | fragment F on User { 11 | id 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/space_in_variable.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo(size: $ 3 | # comment between $ and variable identifier 4 | photoSize 5 | ) 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document_with_error_recovery/fixtures/argument-missing-value-2.graphql: -------------------------------------------------------------------------------- 1 | fragment Test on User { 2 | photo( 3 | s: 4 | size1: $size 5 | size2: $size 6 | ) 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/defer_stream/fixtures/stream.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment FeedbackFragment on Feedback { 4 | id 5 | actor @stream(initialCount: 1) { 6 | name 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/linked-field-no-log.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on User { 2 | id 3 | profile_picture @required(action: NONE) { 4 | uri 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/linked-field-throw.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledActorsRendererFragment on User { 2 | id 3 | profile_picture @required(action: THROW) { 4 | uri 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/client-side-updatable.graphql: -------------------------------------------------------------------------------- 1 | query clientSideOnlyQuery @updatable { 2 | foo 3 | } 4 | 5 | # %extensions% 6 | 7 | extend type Query { 8 | foo: Boolean 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/directive-linked-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) @customDirective(level: 1) { 4 | id 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/directive-scalar-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) { 4 | id @customDirective(level: 1) 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/MutationWithInvalidSuffix.invalid.graphql: -------------------------------------------------------------------------------- 1 | mutation MutationWithInvalidSuffixQuery { 2 | commentCreate(input: null) { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/aliased-inline-fragment-spread-without-type-condition-fragment-root.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on User { 2 | ... @alias(as: "aliased_fragment") { 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Foo.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | type Foo { 4 | client_name: String 5 | profile_picture(scale: Float): Image 6 | bar: Bar 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/dependency-analyzer/tests/ir/fixtures/definitions-only-change-query.graphql: -------------------------------------------------------------------------------- 1 | # Q2 2 | query Q1 { 3 | me { 4 | id 5 | name 6 | } 7 | } 8 | 9 | query Q2 { 10 | me { 11 | id 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/extract-graphql/tests/extract/fixtures/simple.flow: -------------------------------------------------------------------------------- 1 | function MyComponent() { 2 | useFragment(graphql` 3 | fragment Test on User { 4 | __typename 5 | } 6 | `, user) 7 | return
Test
; 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive_missing_required_argument.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | me { 4 | name @customDirective # directive missing level argument 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fixme_fat_interface_on_union.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | query Test { 4 | # this is a union 5 | maybeNode { 6 | doesNotExist @fixme_fat_interface 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/unterminated_string.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | { 3 | friends( 4 | arg: "unterminated string 5 | ) { 6 | count 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/unknown-enum-arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment UserFragment on User { 3 | checkins(environments: UNKNOWN_ENUM_VALUE) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_var_defs_with_directives.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery($id: ID @int_max_value, $count: Int! = 5 @int_max_value) { 2 | my_alias: node(id: $id) { 3 | id 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/default_alias_on_inline_fragment_without_type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Node { 3 | ... @alias { 4 | name 5 | } 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_test_operation/fixtures/prod_query.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | query ProdQuery @relay_test_operation { 4 | node(id: "test-id") { 5 | id 6 | } 7 | } 8 | # %extensions% -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/duplicate-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | name 4 | ... on User { 5 | name @required(action: LOG) 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/skip_unused_variables/fixtures/non-nullable-variable-with-default.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | query Query($id: ID! = "12345") { 4 | node(id: $id) { 5 | id 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_required_arguments/fixtures/argument-on-field.graphql: -------------------------------------------------------------------------------- 1 | query argumentOnFieldTestQuery { 2 | node { 3 | hometown { 4 | nameWithArgs(capitalize: true) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-non-null-item-in-non-null-plural-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | parents { 3 | name @required(action: LOG) 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow_with_custom_id/fixtures/simple.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedField on User { 2 | global_id 3 | name 4 | profilePicture { 5 | uri 6 | width 7 | height 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/aliased-inline-fragment-spread-without-type-condition-fragment-root.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on User { 2 | ... @alias(as: "named_fragment") { 3 | name 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-input-type-interface.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | interface Node { 4 | id: ID 5 | } 6 | input InvalidInput { 7 | value: String 8 | node: Node 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-interface-implements-noninterface.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | id: ID 5 | } 6 | 7 | interface Page implements User { 8 | id: ID 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/duplicate_arguments.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment DuplicateArguments on User { 3 | url(relative: true, relative: true) 4 | @customDirective(level: 1, level: 2) 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-fragment-within-wrong-parent-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on User { 3 | ... on Node { 4 | ... on Page { 5 | __typename 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/find_subtype.graphql: -------------------------------------------------------------------------------- 1 | # should not match, since this could be a false positive 2 | fragment TestLinkedFieldFragment on Actor { 3 | name 4 | } 5 | 6 | %arguments% 7 | User name 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/linked_field.nomatch.graphql: -------------------------------------------------------------------------------- 1 | fragment TestLinkedFieldFragment on Query { 2 | me { # User type 3 | name 4 | } 5 | } 6 | 7 | %arguments% 8 | MaybeNodeInterface name 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-fragment-on-interface.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on Node { 3 | ... on Actor { 4 | name @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/refetchable.graphql: -------------------------------------------------------------------------------- 1 | fragment FlowRefetchableFragment on Node 2 | @refetchable(queryName: "FlowRefetchableFragmentQuery") { 3 | id 4 | ... on User { 5 | name 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/argument-complex-object.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query ObjectArgument($text: String!) { 3 | checkinSearchQuery(query: {query: $text, query: "YES"}) { 4 | query 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/single-value-array-of-objects.graphql: -------------------------------------------------------------------------------- 1 | query SingleValueArrayQuery { 2 | route(waypoints: {lat: "123", lon: "456"}) { 3 | steps { 4 | lat 5 | lon 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/generate_id_field/fixtures/abstract-plural.graphql: -------------------------------------------------------------------------------- 1 | query CommentQuery { 2 | node(id: "comment") { 3 | ... on Comment { 4 | actors { 5 | id 6 | } 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/multiple-required-fields.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query EnabledUserQuery { 3 | me @required(action: NONE) @required(action: NONE) { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-item-in-plural-field.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | screennames { 4 | name 5 | service @required(action: LOG) 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir-validations/tests/validate_selection_conflict/fixtures/same-alias-on-different-types.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | me { 4 | same_alias: name 5 | same_alias: canViewerComment 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/compact/fixtures/single-value-array-of-objects.graphql: -------------------------------------------------------------------------------- 1 | query SingleValueArrayQuery { 2 | route(waypoints: {lat: "123", lon: "456"}) { 3 | steps { 4 | lat 5 | lon 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/single-value-array-of-objects.graphql: -------------------------------------------------------------------------------- 1 | query SingleValueArrayQuery { 2 | route(waypoints: {lat: "123", lon: "456"}) { 3 | steps { 4 | lat 5 | lon 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/duplicate_query_name.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment duplicateFragmentName on User { 3 | name 4 | } 5 | 6 | fragment duplicateFragmentName on User { 7 | age 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment-aliased-typename.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment AssignableFragment on Page @assignable { 3 | but_why_would_you_do_this: __typename 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment-directive-on-typename.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment AssignableFragment on Page @assignable { 3 | __typename @required(action: LOG) 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/declarative_connection/fixtures/delete-from-store.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentDeleteMutation($input: CommentDeleteInput) { 2 | commentDelete(input: $input) { 3 | deletedCommentId @deleteRecord 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/refetchable_fragment/fixtures/fragment-on-interface-without-id.graphql: -------------------------------------------------------------------------------- 1 | fragment RefetchableFragment on AllConcreteTypesImplementNode 2 | @refetchable(queryName: "RefetchableFragmentQuery") { 3 | count 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/required-with-different-actions.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query EnabledUserQuery { 3 | me @required(action: NONE) @required(action: THROW) { 4 | id 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_scalar_field.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_field 3 | } 4 | %extensions% 5 | type MyNewType { 6 | some_old_field: String @deprecated 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-raw-response-type.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery @raw_response_type { 2 | me @required(action: LOG) { 3 | id @required(action: LOG) 4 | name @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/refetchable.graphql: -------------------------------------------------------------------------------- 1 | fragment FlowRefetchableFragment on Node 2 | @refetchable(queryName: "FlowRefetchableFragmentQuery") { 3 | id 4 | ... on User { 5 | name 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /website/docs/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /compiler/crates/docblock-syntax/README.md: -------------------------------------------------------------------------------- 1 | # docblock_syntax 2 | 3 | Parse JavaScript Docblocks into an AST. 4 | 5 | ## Development 6 | 7 | Note that snapshots can be updated by running tests with the 8 | `UPDATE_SNAPSHOTS=1` environment variable set. 9 | -------------------------------------------------------------------------------- /compiler/crates/fixture-tests/tests/uppercase/fixtures/hello.expected: -------------------------------------------------------------------------------- 1 | ==================================== INPUT ==================================== 2 | Hello 3 | ==================================== OUTPUT =================================== 4 | HELLO 5 | -------------------------------------------------------------------------------- /compiler/crates/fixture-tests/tests/uppercase/fixtures/world.expected: -------------------------------------------------------------------------------- 1 | ==================================== INPUT ==================================== 2 | world 3 | ==================================== OUTPUT =================================== 4 | WORLD 5 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fragment-spread-on-wrong-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Image { 3 | uri 4 | } 5 | 6 | query myQuery { 7 | node(id: "") { 8 | ...Foo 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/list-argument-complex-object.graphql: -------------------------------------------------------------------------------- 1 | query ListArgumentQuery($waypoint: WayPoint!) { 2 | route(waypoints: [$waypoint, {lat: "0.0", lon: "0.0"}]) { 3 | steps { 4 | note 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-codegen/tests/aliased_fragments/fixtures/aliased_inline_fragment_spread.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "aliased_fragment") { 5 | name 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/missing-argument-on-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query missingArgumentOnFieldTestQuery { 3 | node { 4 | hometown { 5 | nameWithArgs 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_test_operation/fixtures/test_simple_query.graphql: -------------------------------------------------------------------------------- 1 | query SimpleQuery @relay_test_operation { 2 | node(id: "test-id") { 3 | id 4 | ... on User { 5 | name 6 | } 7 | } 8 | } 9 | # %extensions% -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-fragment-on-interface-within-linked-field.graphql: -------------------------------------------------------------------------------- 1 | fragment EnabledFoo on Node { 2 | ... on Actor { 3 | address { 4 | city @required(action: LOG) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/log-action-bubble-to-throw.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | address @required(action: THROW) { 4 | city @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/none-action-bubble-to-log.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | address @required(action: LOG) { 4 | city @required(action: NONE) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/directive-inline-fragment.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) { 4 | ... on Page @defer { 5 | __typename 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/inline-fragment-interface-to-interface.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) { 4 | ... on FeedUnit { 5 | id 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/MutationWithInvalidName.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | mutation MutationWithAnotherNameMutation { 3 | commentCreate(input: null) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/SubscriptionWithInvalidSuffix.invalid.graphql: -------------------------------------------------------------------------------- 1 | subscription SubscriptionWithInvalidSuffixMutation { 2 | feedbackLikeSubscribe(input: null) { 3 | __typename 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/aliased-inline-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "aliased_fragment") { 5 | name 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-item-in-required-plural-field.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | me { 3 | neighbors @required(action: NONE) { 4 | name @required(action: NONE) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/aliased-inline-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "named_fragment") { 5 | name 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-bubbles-to-item-in-plural-field.graphql: -------------------------------------------------------------------------------- 1 | fragment NonNullFragment on User { 2 | firstName 3 | screennames { 4 | name 5 | service @required(action: LOG) 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-raw-response-type.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery @raw_response_type { 2 | me @required(action: LOG) { 3 | id @required(action: LOG) 4 | name @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /packages/react-relay/__tests__/__snapshots__/ReactRelayFragmentContainer-test.js.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`ReactRelayFragmentContainer can be unwrapped in tests 1`] = ` 4 |
5 | Unwrapped 6 |
7 | `; 8 | -------------------------------------------------------------------------------- /packages/react-relay/__tests__/__snapshots__/ReactRelayRefetchContainer-test.js.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`ReactRelayRefetchContainer can be unwrapped in tests 1`] = ` 4 |
5 | Unwrapped 6 |
7 | `; 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/complex-object-with-missing-fields.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | mutation LikeMutation($feedbackId: ID!) { 3 | feedbackLikeStrict(input: {feedbackId: $feedbackId}) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/linked-handle-field-with-key.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedHandleField on User { 2 | friends(first: 10) 3 | @__clientField(handle: "clientFriends", key: "LinkedHandleField_friends") { 4 | count 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/query-with-raw-response-type-directive.graphql: -------------------------------------------------------------------------------- 1 | query queryWithRawResponseTypeDirective_ViewerQuery @raw_response_type { 2 | viewer { 3 | actor { 4 | id 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_directive/fixtures/assignable-fragment-directive-other-directives.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment AssignableFragment on Page @assignable @refetchable(queryName: "Foo") { 3 | __typename 4 | } 5 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/declarative_connection/fixtures/delete-from-store-plural.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentsDeleteMutation($input: CommentsDeleteInput) { 2 | commentsDelete(input: $input) { 3 | deletedCommentIds @deleteRecord 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/aliased_inline_fragment.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "aliased_fragment") { 5 | name 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/none-action-bubble-to-throw.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | address @required(action: THROW) { 4 | city @required(action: NONE) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/refetchable-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment RefetchableFragment on Node 2 | @refetchable(queryName: "RefetchableFragmentQuery") { 3 | id 4 | fragAndField: profilePicture { 5 | uri 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-object-extension-duplicated-server-field.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | name: String 5 | } 6 | 7 | # %extensions% 8 | 9 | extend type User { 10 | name: ID 11 | } 12 | -------------------------------------------------------------------------------- /packages/react-relay/__tests__/__snapshots__/ReactRelayPaginationContainer-test.js.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`ReactRelayPaginationContainer can be unwrapped in tests 1`] = ` 4 |
5 | Unwrapped 6 |
7 | `; 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/linked-handle-field.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedHandleField on User { 2 | friends(first: 10) 3 | @__clientField(handle: "clientFriends") 4 | @__clientField(handle: "otherFriends") { 5 | count 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/explicit-null-argument.graphql: -------------------------------------------------------------------------------- 1 | query explicitNullArgument_TestQuery { 2 | # The compiler currently strips this null which isn't right. 3 | node(id: null) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/selection_set_conflict_alias_covering_name.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query selectionSetConflictAliasCoveringNameQuery { 3 | me { 4 | name 5 | name: canViewerComment 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/apply_fragment_arguments/fixtures/deletes-unreferenced-fragments.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery($id: ID!) { 2 | node(id: $id) { 3 | id 4 | } 5 | } 6 | 7 | fragment UnreferencedFragment on User { 8 | id 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-fragment-on-union.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on EnabledUserNameRenderer { 3 | ... on UserNameRenderer { 4 | __typename @required(action: LOG) 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_directive_arg.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on User { 2 | id @my_directive(my_arg: "Hello") 3 | } 4 | %extensions% 5 | 6 | directive @my_directive(my_arg: String! @deprecated) on FIELD 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_required_arguments/fixtures/missing-argument-on-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query missingArgumentOnFieldTestQuery { 3 | node { 4 | hometown { 5 | nameWithArgs 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-through-inline-fragments-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | __typename 3 | ... on User { 4 | ... on User { 5 | name @required(action: LOG) 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/refetchable-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment RefetchableFragment on Node 2 | @refetchable(queryName: "RefetchableFragmentQuery") { 3 | id 4 | fragAndField: profilePicture { 5 | uri 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-sdl.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | directive @source(name: String!) on OBJECT 4 | 5 | type User { 6 | id: ID 7 | } 8 | 9 | type Page implements User @source("") { 10 | id: ID 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fragment-with-argument-type-syntax-error.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment Foo on User @argumentDefinitions( 4 | # syntax error, should be [ID] 5 | ids: {type: "Array"} 6 | ) { 7 | id 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/basic_arg_defs.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | after: {type: "ID"} 4 | first: {type: "Int", defaultValue: 5} 5 | size: {type: "[Int]"} 6 | ) { 7 | id 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/inline_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment TestInlineFragment on Query { 2 | me { # User type 3 | ... on Actor { 4 | name 5 | } 6 | } 7 | } 8 | 9 | %arguments% 10 | Actor name 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/generate_id_field/fixtures/node-union.graphql: -------------------------------------------------------------------------------- 1 | query UnionQuery { 2 | maybeNode { 3 | # ... on Node { id } is autogenerated here because Node is a possible type 4 | ... on NonNode { 5 | name 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/conditional.graphql: -------------------------------------------------------------------------------- 1 | fragment ConditionField on Node { 2 | id @include(if: $condition) 3 | } 4 | 5 | fragment NestedCondition on Node { 6 | ... @include(if: $condition) { 7 | id 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /packages/relay-test-utils-internal/schema-extensions/Query.graphql: -------------------------------------------------------------------------------- 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. 2 | 3 | extend type Query { 4 | client_root_field: String 5 | updatable_scalar_field: OpaqueScalarType 6 | } 7 | 8 | scalar OpaqueScalarType 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/argument_definitions.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFragment on User 2 | @argumentDefinitions( 3 | id: {type: "ID", directives: ["@configurable"]} 4 | size: {type: "[Int]", defaultValue: [100]} 5 | ) { 6 | __typename 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_schema_document/fixtures/schema_with_leading_comment.graphql: -------------------------------------------------------------------------------- 1 | """Description of the schema as per https://github.com/graphql/graphql-spec/pull/466""" 2 | schema { 3 | query: RootQueryType 4 | mutation: RootMutationType 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_arg_defs.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | after: {type: "ID"} 4 | first: {type: "Int", defaultValue: 5} 5 | size: {type: "[Int]"} 6 | ) { 7 | id 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_arg_defs_type.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | after: {type: ID} 4 | first: {type: "Int", defaultValue: 5} 5 | size: {type: [Int]} 6 | ) { 7 | id 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/selection_set_conflict_different_name.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query selectionSetConflictDifferentNameQuery { 3 | me { 4 | same_alias: name 5 | same_alias: canViewerComment 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/client_edges/fixtures/unexpected-waterfall.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | fragment Foo_user on User { 3 | name @waterfall 4 | nearest_neighbor @waterfall { 5 | __typename 6 | } 7 | } 8 | 9 | # %extensions% 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/aliased_inline_fragment_without_type_condition.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... @alias(as: "aliased_fragment") { 5 | name 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/refetchable_fragment/fixtures/fragment-with-relay-plural.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment RefetchableFragment on User 3 | @relay(plural: true) 4 | @refetchable(queryName: "RefetchableFragmentQuery") { 5 | id 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/doubly-nested-fragment-spread.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery @updatable { 3 | node(id: 4) { 4 | ... on Page { 5 | ... on Node { 6 | id 7 | } 8 | } 9 | } 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_static_args/fixtures/required-with-dynamic-arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query EnabledUserQuery($action: RequiredFieldAction!) { 3 | me @required(action: $action) { 4 | id 5 | } 6 | } 7 | 8 | # %extensions% -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_unused_variables/fixtures/query-with-unused-variable-error-suppressed.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithUnusedVariable($unused: ID) 2 | @DEPRECATED__relay_ignore_unused_variables_error { 3 | node { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-non-null-linked-field-through-inline-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | nearest_neighbor { 3 | ... on User { 4 | name @required(action: LOG) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/conditional.graphql: -------------------------------------------------------------------------------- 1 | fragment ConditionField on Node { 2 | id @include(if: $condition) 3 | } 4 | 5 | fragment NestedCondition on Node { 6 | ... @include(if: $condition) { 7 | id 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-bubbles-through-inline-fragments-to-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | __typename 3 | ... on User { 4 | ... on User { 5 | name @required(action: LOG) 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v11.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v12.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v13.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v14.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v15.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v16.0.0/api-reference/types/UploadableMap.md: -------------------------------------------------------------------------------- 1 | #### Type `UploadableMap` 2 | 3 | * An object whose values are [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) or [`Blob`](https://developer.mozilla.org/en-US/docs/Web/API/Blob). 4 | -------------------------------------------------------------------------------- /compiler/crates/dependency-analyzer/tests/ast/fixtures/definitions-only.graphql: -------------------------------------------------------------------------------- 1 | query Q1 { 2 | me { 3 | ...F1 4 | } 5 | } 6 | fragment F1 on User { 7 | ...F2 8 | } 9 | fragment F2 on User { 10 | ...F3 11 | } 12 | fragment F3 on User { 13 | name 14 | } 15 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fragment-spread-within-wrong-parent-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment PageFrag on Page { 3 | __typename 4 | } 5 | 6 | fragment Foo on User { 7 | ... on Node { 8 | ...PageFrag 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/linked-handle-field-with-filters.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedHandleField on User { 2 | friends(first: 10, orderby: $orderby) 3 | @__clientField(handle: "clientFriends", filters: ["first", "orderby"]) { 4 | count 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/compact/fixtures/basic_query.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery($id: ID) { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: 5) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/basic_query.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery($id: ID) { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: 5) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/scalar-handle-field.graphql: -------------------------------------------------------------------------------- 1 | query scalarHandleField_ScalarHandleFieldQuery($id: ID!) { 2 | node(id: $id) { 3 | ... on User { 4 | name @__clientField(handle: "clientName") 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-docblock/README.md: -------------------------------------------------------------------------------- 1 | # relay_docblock 2 | 3 | Extract and valdiate Relay-specific information from Docblocks. 4 | 5 | ## Development 6 | 7 | Note that snapshots can be updated by running tests with the 8 | `UPDATE_SNAPSHOTS=1` environment variable set. 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/abstract-assignable-fragment-spread-on-concrete-type.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | me { 3 | ...Assignable_node 4 | } 5 | } 6 | 7 | fragment Assignable_node on Node @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/duplicate-field-different-actions.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | name @required(action: NONE) 4 | ... on User { 5 | name @required(action: LOG) 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_field_arg.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_field(my_arg: "Hello") 3 | } 4 | %extensions% 5 | type MyNewType { 6 | some_old_field(my_arg: String! @deprecated): String 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_linked_field.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_user { 3 | name 4 | } 5 | } 6 | %extensions% 7 | type MyNewType { 8 | some_old_user: User @deprecated 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/QueryWithValidName.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithValidNameQuery { 2 | me { 3 | name 4 | } 5 | } 6 | 7 | query QueryWithValidNameSecondQuery { 8 | me { 9 | name 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_relay_directives/fixtures/unmasked-spread.graphql: -------------------------------------------------------------------------------- 1 | fragment UserProfile on User { 2 | profilePicture { 3 | ...PhotoFragment @relay(mask: false) 4 | } 5 | } 6 | 7 | fragment PhotoFragment on Image { 8 | uri 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_unused_variables/fixtures/query-with-invalid-error-suppression.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query QueryWithId($id: ID) @DEPRECATED__relay_ignore_unused_variables_error { 3 | node(id: $id) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/regular-query-with-assignable-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query Foo { 2 | viewer { 3 | ...Assignable_viewer 4 | } 5 | } 6 | 7 | fragment Assignable_viewer on Viewer @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/dependency-analyzer/tests/ir/fixtures/recursive-fragments.graphql: -------------------------------------------------------------------------------- 1 | # Q1 2 | query Q1 { 3 | me { 4 | ...F1 5 | } 6 | } 7 | 8 | fragment F1 on User { 9 | ...F1 10 | ...F2 11 | } 12 | 13 | fragment F2 on User { 14 | ...F2 15 | __typename 16 | } 17 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/linked-handle-filter.graphql: -------------------------------------------------------------------------------- 1 | fragment LinkedHandleField on User { 2 | friends(first: 10) 3 | @__clientField(handle: "clientFriends", filters: ["first"]) 4 | @__clientField(handle: "otherFriends") { 5 | count 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_query.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery($id: ID) { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: 5) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/assignable-fragment-spread-top-level.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Actor { 3 | ...Assignable_actor 4 | } 5 | 6 | fragment Assignable_actor on Actor @assignable { 7 | __typename 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/declarative_connection/fixtures/delete-on-unspported-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | mutation CommentDeleteMutation($input: CommentDeleteInput) { 3 | commentDelete(input: $input) { 4 | __typename @deleteRecord 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-fragment-on-concrete-in-interface.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on Node { 3 | ... on Actor { 4 | ... on User { 5 | name @required(action: LOG) 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_abstract_in_concrete.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Query { 2 | me { 3 | ...Updatable_node 4 | } 5 | } 6 | 7 | fragment Updatable_node on Node @updatable { 8 | __id 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_global_variables/fixtures/query-with-undefined-variable.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | query QueryWithUnusedVariable { 3 | node(id: $id) { 4 | id 5 | } 6 | node2: node(id: $id2) { 7 | id 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/aliased-inline-fragment-spread-without-type-condition-linked-field.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... @alias(as: "aliased_fragment") { 5 | name 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/aliased-inline-fragment-spread-without-type-condition-query-root.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | ... @alias(as: "aliased_fragment") { 3 | me { 4 | id 5 | name 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-to-plural-fragment-root.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User @relay(plural: true) { 2 | name @required(action: LOG) 3 | } 4 | 5 | fragment SomeOtherFragment on User @relay(plural: true) { 6 | name 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-within-aliased-inline-fragment.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "aliased_fragment") { 5 | name @required(action: NONE) 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-operation-plural-field-with-spreads.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | nodes(ids: [4]) { 3 | ...Updatable_user 4 | } 5 | } 6 | 7 | fragment Updatable_user on User @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/regular-query-with-assignable-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query Foo { 2 | viewer { 3 | ...Assignable_viewer 4 | } 5 | } 6 | 7 | fragment Assignable_viewer on Viewer @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-duplicate-query-operation.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | schema { 4 | query: Query1 5 | query: Query2 6 | } 7 | 8 | type Query1 { 9 | s: String 10 | } 11 | 12 | type Query2 { 13 | s: String 14 | } 15 | -------------------------------------------------------------------------------- /website/docs/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/client-only-query.graphql: -------------------------------------------------------------------------------- 1 | query clientOnlyQuery { 2 | __id 3 | ...clientOnlyQueryFragment @skip(if: true) 4 | } 5 | 6 | fragment clientOnlyQueryFragment on Query { 7 | me { 8 | name 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/duplicate_fragment_name.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query duplicateQueryName { 3 | me { 4 | __typename 5 | } 6 | } 7 | 8 | query duplicateQueryName { 9 | me { 10 | __typename 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/concrete-assignable-fragment-spread-on-matching-concrete-type.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | me { 3 | ...Assignable_user 4 | } 5 | } 6 | 7 | fragment Assignable_user on User @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/refetchable_fragment/fixtures/fragment-on-interface-which-implementations-not-implement-node.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment UserName on UserNameRenderable 3 | @refetchable(queryName: "RefetchableFragmentQuery") { 4 | name 5 | } 6 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_test_operation/fixtures/test_query_with_enums.graphql: -------------------------------------------------------------------------------- 1 | query QueryWitEnums @relay_test_operation { 2 | node(id: "test-id") { 3 | id 4 | ... on User { 5 | name 6 | environment 7 | } 8 | } 9 | } 10 | # %extensions% -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/conflicting-required-status-across-aliased-inline-fragments.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | ... on MaybeNodeInterface @alias(as: "aliased_fragment") { 3 | name @required(action: NONE) 4 | } 5 | name 6 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_top_level.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Viewer { 3 | ...Updatable_viewer 4 | } 5 | 6 | fragment Updatable_viewer on Viewer @updatable { 7 | __typename 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_field_with_arguments.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_field(my_arg: "Hello") 3 | } 4 | %extensions% 5 | type MyNewType { 6 | some_old_field(my_arg: String!): String @deprecated 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/SubscriptionWithInvalidName.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | subscription SubscriptionWithAnyOtherNameIsInvalidSubscription { 3 | feedbackLikeSubscribe(input: null) { 4 | __typename 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_no_double_underscore_alias/fixtures/double_underscore.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery($Id: ID!) { 3 | node(id: $Id) { 4 | __foo: id 5 | ... on User { 6 | __bar: name 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/aliased-inline-fragment-spread-without-type-condition-linked-field.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... @alias(as: "named_fragment") { 5 | name 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/aliased-inline-fragment-spread-without-type-condition-query-root.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | ... @alias(as: "named_fragment") { 3 | me { 4 | id 5 | name 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-within-aliased-inline-fragment.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | me { 3 | id 4 | ... on User @alias(as: "named_fragment") { 5 | name @required(action: NONE) 6 | } 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/simple-use-import-type-syntax.graphql: -------------------------------------------------------------------------------- 1 | # typegen_config.use_import_type_syntax = true 2 | 3 | fragment LinkedField on User { 4 | name 5 | profilePicture { 6 | uri 7 | width 8 | height 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-object-extension-local-duplicated-fields.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | name: String 5 | } 6 | 7 | # %extensions% 8 | 9 | extend type User { 10 | nickname: String 11 | nickname: ID 12 | } 13 | -------------------------------------------------------------------------------- /vscode-extension/src/constants.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Meta Platforms, Inc. and affiliates. 3 | * 4 | * This source code is licensed under the MIT license found in the 5 | * LICENSE file in the root directory of this source tree. 6 | */ 7 | 8 | export const SEMVER_RANGE = '>=14'; 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/basic_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment on Query { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: $count) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_query_with_float.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery($id: ID) { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: 5.0) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/client_fields_only_no_fragment_invalid.graphql: -------------------------------------------------------------------------------- 1 | query clientFieldsOnlyNoFragmentInvalidQuery { 2 | my_alias: client_field 3 | } 4 | 5 | # %extensions% 6 | 7 | extend type Query { 8 | client_field: String 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/fragment-alias.graphql: -------------------------------------------------------------------------------- 1 | query fragmentAliasNotEnabled_Query { 2 | ...fragmentAliasNotEnabled_fragment @alias 3 | } 4 | 5 | fragment fragmentAliasNotEnabled_fragment on Query { 6 | me { 7 | id 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/inline_fragment_also_matches_outer_type.graphql: -------------------------------------------------------------------------------- 1 | fragment TestInlineFragment on Query { 2 | me { # User type 3 | ... on Actor { 4 | name 5 | } 6 | } 7 | } 8 | 9 | %arguments% 10 | User name 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/concrete-assignable-fragment-spread-on-abstract-type.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | node(id: "4") { 3 | ...Assignable_user 4 | } 5 | } 6 | 7 | fragment Assignable_user on User @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/defer_stream/fixtures/query-with-defer.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithDefer { 2 | me { 3 | id 4 | ...DeferredFragment @defer(label: "DeferredFragmentLabel") 5 | } 6 | } 7 | 8 | fragment DeferredFragment on User { 9 | id 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_non_node_id_fields/fixtures/valid-id-selection.graphql: -------------------------------------------------------------------------------- 1 | fragment SimpleUser_fragment on SimpleUser { 2 | id 3 | name 4 | } 5 | 6 | # %extensions% 7 | 8 | type SimpleUser implements Node { 9 | id: ID! 10 | name: String 11 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/inline-fragment-on-interface-with-linked-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on Node { 3 | ... on Actor { 4 | address @required(action: LOG) { 5 | __typename 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_abstract_in_same_abstract.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Query { 2 | node { 3 | ...Updatable_node 4 | } 5 | } 6 | 7 | fragment Updatable_node on Node @updatable { 8 | __id 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_field_with_reason.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_field 3 | } 4 | %extensions% 5 | type MyNewType { 6 | some_old_field: String @deprecated(reason: "This field is as old as dirt!") 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_required_arguments/fixtures/missing-argument-on-directive.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | query missingArgumentOnDirectiveViewerQuery { 4 | node { 5 | body @customDirective { 6 | text 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/mutation-input-has-array.graphql: -------------------------------------------------------------------------------- 1 | mutation InputHasArray($input: UpdateAllSeenStateInput) @raw_response_type { 2 | viewerNotificationsUpdateAllSeenState(input: $input) { 3 | stories { 4 | actorCount 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-operation-assignable-fragment.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | viewer { 3 | ...Assignable_viewer 4 | } 5 | } 6 | 7 | fragment Assignable_viewer on Viewer @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-input-type.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | id: ID 5 | } 6 | 7 | enum Option { 8 | SOME 9 | NONE 10 | } 11 | 12 | input InvalidInput { 13 | id: String 14 | enum: Option 15 | user: User 16 | } 17 | -------------------------------------------------------------------------------- /compiler/rustfmt.toml: -------------------------------------------------------------------------------- 1 | # Get help on options with `rustfmt --help=config` 2 | # Please keep these in alphabetical order. 3 | edition = "2021" 4 | group_imports = "StdExternalCrate" 5 | imports_granularity = "Item" 6 | merge_derives = false 7 | use_field_init_shorthand = true 8 | version = "Two" 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive-include.graphql: -------------------------------------------------------------------------------- 1 | fragment TestFragment on User { 2 | id @include(if: $Cond) 3 | ... on User @include(if: $Cond) { 4 | firstName 5 | } 6 | ...Foo @include(if: $Cond) 7 | } 8 | 9 | fragment Foo on User { 10 | id 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/field-arguments.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | task(number: 123) { 3 | title 4 | } 5 | settings(environment: WEB) { 6 | notificationSounds 7 | } 8 | checkinSearchQuery(query: {query: "Relay"}) { 9 | query 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/README.md: -------------------------------------------------------------------------------- 1 | # graphql_syntax 2 | 3 | Lexer, parser, and CST (concrete syntax tree) for the executable subset of GraphQL syntax. 4 | 5 | ## Development 6 | 7 | Note that snapshots can be updated by running tests with the `UPDATE_SNAPSHOTS=1` environment variable set. 8 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/operation_printer/fixtures/field-arguments.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User { 2 | name 3 | likers(first: null) { 4 | count 5 | } 6 | } 7 | 8 | query MyQuery($id: ID) { 9 | node(id: $id) { 10 | ...UserFragment 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/basic_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment on Query { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: $count) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/unions.graphql: -------------------------------------------------------------------------------- 1 | query unions_UnionQuery { 2 | maybeNode { 3 | ... on NonNode { 4 | name 5 | } 6 | ... on Story { 7 | id 8 | body { 9 | text 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/abstract-assignable-fragment-spread-on-matching-abstract-type.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | node(id: "4") { 3 | ...Assignable_node 4 | } 5 | } 6 | 7 | fragment Assignable_node on Node @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_concrete_in_same_concrete.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Query { 2 | story { 3 | ...Updatable_story 4 | } 5 | } 6 | 7 | fragment Updatable_story on Story @updatable { 8 | __id 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/mutation-input-has-array.graphql: -------------------------------------------------------------------------------- 1 | mutation InputHasArray($input: UpdateAllSeenStateInput) @raw_response_type { 2 | viewerNotificationsUpdateAllSeenState(input: $input) { 3 | stories { 4 | actorCount 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-operation-assignable-fragment.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | viewer { 3 | ...Assignable_viewer 4 | } 5 | } 6 | 7 | fragment Assignable_viewer on Viewer @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/delete-edge.graphql: -------------------------------------------------------------------------------- 1 | mutation deleteEdgeMutation( 2 | $input: CommentDeleteInput 3 | $connections: [ID!]! 4 | ) { 5 | commentDelete(input: $input) { 6 | deletedCommentId @deleteEdge(connections: $connections) 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/abstract-assignable-fragment-spread-on-different-abstract-type.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery { 2 | node(id: "4") { 3 | ...Assignable_actor 4 | } 5 | } 6 | 7 | fragment Assignable_actor on Actor @assignable { 8 | __typename 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/generate_id_field/fixtures/non-node-union.graphql: -------------------------------------------------------------------------------- 1 | query UnionQuery { 2 | neverNode { 3 | # ... on Node { id } is not autogenerated here since no concrete type 4 | # implements Node 5 | ... on NonNode { 6 | name 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/skip_redundant_nodes/fixtures/dont-skip-different-ids.graphql: -------------------------------------------------------------------------------- 1 | query DontSkipDifferentIds { 2 | viewer { 3 | actor { 4 | id 5 | hometown { 6 | id # id of a different parent field, can't skip 7 | } 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-operation-plural-field-with-spreads.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | nodes(ids: [4]) { 3 | ...Updatable_user 4 | } 5 | } 6 | 7 | fragment Updatable_user on User @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/graphql-syntax/tests/parse_executable_document/fixtures/multiple_parse_errors.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query Test( 3 | %%%% # unexpected % signs 4 | $arg: String, 5 | width: Int # missing $ 6 | height: Int # missing $ 7 | ) { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/string-enum-fragment-arg.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | environments: {type: "[Environment!]!", defaultValue: [WEB]} 4 | ) { 5 | checkins(environments: $environments) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/updatable-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query updatableFragmentSpreadQuery { 2 | me { 3 | ...updatableFragmentSpread_user 4 | } 5 | } 6 | 7 | fragment updatableFragmentSpread_user on User @updatable { 8 | firstName 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/defer_stream/fixtures/query-with-stream.graphql: -------------------------------------------------------------------------------- 1 | query QueryWithStream($id: ID!) { 2 | node(id: $id) { 3 | ... on Feedback { 4 | actors @stream(initialCount: 1, label: "StreamedActorsLabel") { 5 | name 6 | } 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/refetchable_fragment/fixtures/fragment-on-node-with-id-argument-used.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment RefetchableFragment on User 3 | @refetchable(queryName: "RefetchableFragmentQuery") { 4 | friends(after: $id) { 5 | __typename 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_resolvers/fixtures/missing-fragment-name.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo_user on User { 2 | pop_star_name 3 | } 4 | 5 | # %extensions% 6 | 7 | extend type User { 8 | pop_star_name: String @relay_resolver(import_path: "PopStarNameResolver", live: true) 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/non-assignable-fragment-spreads.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment NonAssignable_page on Page { 3 | __typename 4 | } 5 | 6 | query TestQuery @updatable { 7 | node(id: 4) { 8 | ...NonAssignable_page 9 | } 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-chain-bubbles-to-non-null-linked-field-through-inline-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment SomeFragment on User { 2 | nearest_neighbor { 3 | profile_picture @required(action: LOG) { 4 | uri @required(action: LOG) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-within-aliased-inline-fragment-on-abstract.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | node(id: "1") { 3 | ... on MaybeNodeInterface @alias(as: "aliased_fragment") { 4 | name @required(action: NONE) 5 | } 6 | } 7 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/scalar-field.graphql: -------------------------------------------------------------------------------- 1 | fragment ScalarField on User { 2 | id 3 | name 4 | websites 5 | traits 6 | aliasedLinkedField: birthdate { 7 | aliasedField: year 8 | } 9 | screennames { 10 | name 11 | service 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/typename-on-union-with-non-matching-aliases.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | ... on User { 3 | __typename 4 | } 5 | ... on Comment { 6 | alias: __typename 7 | } 8 | ... on Feedback { 9 | foo: __typename 10 | } 11 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query updatableFragmentSpreadQuery { 2 | me { 3 | ...updatableFragmentSpread_updatable_user 4 | } 5 | } 6 | 7 | fragment updatableFragmentSpread_updatable_user on User @updatable { 8 | firstName 9 | } 10 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v11.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v12.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v13.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v14.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v15.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v16.0.0/guided-tour/refetching/OssAvoidSuspenseNote.md: -------------------------------------------------------------------------------- 1 | :::note 2 | In future versions of React when concurrent rendering is supported, React will provide an option to support this case and avoid hiding already rendered content with a Suspense fallback when suspending. 3 | ::: 4 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/fragment-with-both-variable-definition-and-directive.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment TestFragment($size: [Int]) on User @argumentDefinitions(if: {type: "Boolean!"}) { 3 | profilePicture(size: $size) @include(if: $if) { 4 | uri 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-fragment-within-invalid-inline-fragment-grandparent.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment Foo on Node { 4 | ... on User { 5 | ... on Node { 6 | ... on Page { 7 | __typename 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/inline-fragment-within-linked-field-and-wrong-inline-fragment.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment Foo on User { 4 | neighbors { 5 | ... on Node { 6 | ... on Page { 7 | __typename 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/lowercase-enum-fragment-arg.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | environments: {type: "[Environment!]!", defaultValue: [web]} 4 | ) { 5 | checkins(environments: $environments) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print_ast/fixtures/string-enum-fragment-arg.graphql: -------------------------------------------------------------------------------- 1 | fragment UserFragment on User 2 | @argumentDefinitions( 3 | environments: {type: "[Environment!]!", defaultValue: [WEB]} 4 | ) { 5 | checkins(environments: $environments) { 6 | __typename 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/find_field_usages/fixtures/multiple_matches.graphql: -------------------------------------------------------------------------------- 1 | fragment TestMultipleMatchesFragment1 on User { 2 | name 3 | ... on Actor { 4 | name 5 | } 6 | } 7 | 8 | fragment TestMultipleMatchesFragment2 on User { 9 | name 10 | } 11 | 12 | %arguments% 13 | User name 14 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/default_alias_on_fragment_spread.graphql: -------------------------------------------------------------------------------- 1 | fragment RelayReaderNamedFragmentsTest_user on User { 2 | name 3 | } 4 | 5 | query RelayReaderNamedFragmentsTest2Query { 6 | me { 7 | ...RelayReaderNamedFragmentsTest_user @alias 8 | } 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/match_transform/fixtures/direct-js-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment NameRendererFragment on User { 3 | id 4 | nameRenderer { 5 | ... on PlainUserNameRenderer { 6 | js(module: "PlainUserNameRenderer.react") 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_actor_change/fixtures/actor-change-no-viewer.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment TestFragment on Query { 4 | story @fb_actor_change { 5 | ...StoryFragment 6 | } 7 | } 8 | 9 | fragment StoryFragment on Story { 10 | seenState 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/duplicate-field-include-directive.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on User { 3 | ... on User @include(if: true) { 4 | name 5 | } 6 | ... on User { 7 | name @required(action: THROW) 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/fragments-are-isolated.graphql: -------------------------------------------------------------------------------- 1 | fragment FragA on User { 2 | id 3 | name 4 | } 5 | 6 | fragment EnabledFragB on User { 7 | id 8 | # This does not match FragA.name, but that should be fine. 9 | name @required(action: LOG) 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/none-action-bubble-to-log-across-inline-fragment.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment EnabledFoo on Comment { 3 | actor @required(action: LOG) { 4 | ... on User { 5 | name @required(action: NONE) 6 | } 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/directive-fragment-spread.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Test_page on Page { 3 | __typename 4 | } 5 | 6 | query TestQuery @updatable { 7 | node(id: 4) { 8 | ...Test_page @customDirective(level: 1) 9 | } 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/type-narrowing.graphql: -------------------------------------------------------------------------------- 1 | query TypeNarrowingQuery @updatable { 2 | node(id: 4) { 3 | ... on Page { 4 | __typename 5 | name 6 | } 7 | ... on Comment { 8 | __typename 9 | firstName 10 | } 11 | } 12 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_connections/fixtures/connection-invalid-type.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query NodeQuery($id: ID!) { 3 | node(id: $id) { 4 | id 5 | ... on Story { 6 | actors @connection { 7 | name 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_directive_arg_with_reason.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on User { 2 | id @my_directive(my_arg: "Hello") 3 | } 4 | %extensions% 5 | 6 | directive @my_directive(my_arg: String! @deprecated(reason: "Use something else, lol.")) on FIELD 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/aliased-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | fragment RelayReaderNamedFragmentsTest_user on User { 2 | name 3 | } 4 | 5 | query RelayReaderNamedFragmentsTest2Query { 6 | me { 7 | ...RelayReaderNamedFragmentsTest_user @alias(as: "aliased_fragment") 8 | } 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/updatable-operation-special-fields.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | me { 3 | id 4 | aliased_id: id 5 | __typename 6 | aliased_typename: __typename 7 | __id 8 | aliased_double_under_id: __id 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-within-aliased-inline-fragment-on-abstract.graphql: -------------------------------------------------------------------------------- 1 | query RelayReaderNamedFragmentsTest2Query { 2 | node(id: "1") { 3 | ... on MaybeNodeInterface @alias(as: "named_fragment") { 4 | name @required(action: NONE) 5 | } 6 | } 7 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/scalar-field.graphql: -------------------------------------------------------------------------------- 1 | fragment ScalarField on User { 2 | id 3 | name 4 | websites 5 | traits 6 | aliasedLinkedField: birthdate { 7 | aliasedField: year 8 | } 9 | screennames { 10 | name 11 | service 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/typename-on-union-with-non-matching-aliases.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Node { 2 | ... on User { 3 | __typename 4 | } 5 | ... on Comment { 6 | alias: __typename 7 | } 8 | ... on Feedback { 9 | foo: __typename 10 | } 11 | } -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/invalid-input-type-union.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | type User { 4 | id: ID 5 | } 6 | 7 | type Page { 8 | token: ID 9 | } 10 | 11 | union Union = User | Page 12 | 13 | input InvalidInput { 14 | value: Boolean 15 | union: Union 16 | } 17 | -------------------------------------------------------------------------------- /compiler/crates/relay-codegen/tests/aliased_fragments/fixtures/aliased_fragment_spread.graphql: -------------------------------------------------------------------------------- 1 | fragment RelayReaderNamedFragmentsTest_user on User { 2 | name 3 | } 4 | 5 | query RelayReaderNamedFragmentsTest2Query { 6 | me { 7 | ...RelayReaderNamedFragmentsTest_user @alias(as: "aliased_fragment") 8 | } 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/delete-edge-plural.graphql: -------------------------------------------------------------------------------- 1 | mutation deleteEdgePluralMutation( 2 | $input: CommentsDeleteInput 3 | $connections: [ID!]! 4 | ) { 5 | commentsDelete(input: $input) { 6 | deletedCommentIds @deleteEdge(connections: $connections) 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/id-as-alias.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment idAsAlias_User_fragment on User { 3 | id: name 4 | } 5 | 6 | fragment idAsAlias_ProfilePicture on User { 7 | profilePicture(size: $size) { 8 | id: uri 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_non_node_id_fields/fixtures/illegal-scalar.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment UserWithIntID_fragment on UserWithIntID { 3 | id 4 | name 5 | } 6 | 7 | # %extensions% 8 | 9 | type UserWithIntID { 10 | id: Int! 11 | name: String! 12 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_typename_on_root/fixtures/valid.expected: -------------------------------------------------------------------------------- 1 | ==================================== INPUT ==================================== 2 | query TestQuery { 3 | me { 4 | name 5 | } 6 | } 7 | ==================================== OUTPUT =================================== 8 | OK 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/aliased-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | fragment RelayReaderNamedFragmentsTest_user on User { 2 | name 3 | } 4 | 5 | query RelayReaderNamedFragmentsTest2Query { 6 | me { 7 | ...RelayReaderNamedFragmentsTest_user @alias(as: "named_fragment") 8 | } 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-fragment-spread.graphql: -------------------------------------------------------------------------------- 1 | query updatableFragmentSpreadQuery { 2 | me { 3 | ...updatableFragmentSpread_updatable_user 4 | } 5 | } 6 | 7 | fragment updatableFragmentSpread_updatable_user on User @updatable { 8 | firstName 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/updatable-operation-special-fields.graphql: -------------------------------------------------------------------------------- 1 | query UpdatableQuery @updatable { 2 | me { 3 | id 4 | aliased_id: id 5 | __typename 6 | aliased_typename: __typename 7 | __id 8 | aliased_double_under_id: __id 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/directive-module-on-field.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Example on User { 3 | friends { 4 | edges { 5 | node { 6 | profilePicture @module(preset: $preset) { 7 | uri 8 | } 9 | } 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/fragment-alias-on-inline-fragment-does-not-get-flattened.graphql: -------------------------------------------------------------------------------- 1 | query fragmentAliasOnInlineFragmentDoesNotGetFlattenedQuery { 2 | me { 3 | ... on User @alias(as: "aliased_fragment") { 4 | name @required(action: NONE) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts_with_custom_id/fixtures/unions.graphql: -------------------------------------------------------------------------------- 1 | query unions_UnionQuery { 2 | maybeNode { 3 | ... on NonNode { 4 | name 5 | } 6 | ... on Story { 7 | global_id 8 | body { 9 | text 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/relay-lsp/tests/hover/fixtures/scalar_field_from_client_schema_extension.graphql: -------------------------------------------------------------------------------- 1 | query MyQuery { 2 | me { 3 | client_sc|hema_field 4 | } 5 | } 6 | 7 | %extension% 8 | 9 | extend type User { 10 | """ 11 | This is a client schema field 12 | """ 13 | client_schema_field: Int 14 | } 15 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/declarative_connection/fixtures/delete-edge-from-connection.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentDeleteMutation( 2 | $input: CommentDeleteInput 3 | $connections: [ID!]! 4 | ) { 5 | commentDelete(input: $input) { 6 | deletedCommentId @deleteEdge(connections: $connections) 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/required_directive/fixtures/required-paths.graphql: -------------------------------------------------------------------------------- 1 | query EnabledFooQuery { 2 | viewer @required(action: LOG) { 3 | actor @required(action: LOG) { 4 | address @required(action: LOG) { 5 | country @required(action: LOG) 6 | } 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_field_arg_with_reason.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on MyNewType { 2 | some_old_field(my_arg: "Hello") 3 | } 4 | %extensions% 5 | type MyNewType { 6 | some_old_field(my_arg: String! @deprecated(reason: "Not supported any more.")): String 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/errors/src/lib.rs: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) Meta Platforms, Inc. and affiliates. 3 | * 4 | * This source code is licensed under the MIT license found in the 5 | * LICENSE file in the root directory of this source tree. 6 | */ 7 | 8 | mod error_combinators; 9 | 10 | pub use error_combinators::*; 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/assignable-fragment-spread-with-directives.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | node(id: "4") { 4 | ...Assignable_user @defer 5 | } 6 | } 7 | 8 | fragment Assignable_user on User @assignable { 9 | __typename 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/fragment_alias_directive/fixtures/alias_on_named_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment RelayReaderNamedFragmentsTest_user on User { 2 | name 3 | } 4 | 5 | query RelayReaderNamedFragmentsTest2Query { 6 | me { 7 | ...RelayReaderNamedFragmentsTest_user @alias(as: "aliased_fragment") 8 | } 9 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/FragmentWithValidName.graphql: -------------------------------------------------------------------------------- 1 | fragment FragmentWithValidName_fragment on User { 2 | name 3 | } 4 | 5 | fragment FragmentWithValidNameFragment on User { 6 | name 7 | } 8 | 9 | fragment FragmentWithValidName on User { 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/fragment-with-valid-name.graphql: -------------------------------------------------------------------------------- 1 | fragment fragmentWithValidName_fragment on User { 2 | name 3 | } 4 | 5 | fragment fragmentWithValidNameFragment on User { 6 | name 7 | } 8 | 9 | fragment fragmentWithValidName on User { 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/custom-scalar-type-import.graphql: -------------------------------------------------------------------------------- 1 | query Viewer($params: JSON) { 2 | viewer { 3 | actor { 4 | ... on User { 5 | profilePicture2(additionalParameters: $params) { 6 | __typename 7 | } 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/dependency-analyzer/tests/ir/fixtures/definitions-only-no-change.expected: -------------------------------------------------------------------------------- 1 | ==================================== INPUT ==================================== 2 | # 3 | query Q1 { 4 | me { 5 | id 6 | name 7 | } 8 | } 9 | ==================================== OUTPUT =================================== 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/selection_set_conflict_with_inline_fragment.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query selectionSetConflictWithInlineFragmentQuery { 3 | username(name: "me") { 4 | same_alias: name 5 | ... on User { 6 | same_alias: id 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/abstract-assignable-fragment-spread-on-concrete-type-in-updatable-fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment Foo on Query @updatable { 2 | me { 3 | ...Assignable_node 4 | } 5 | } 6 | 7 | fragment Assignable_node on Node @assignable { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/declarative_connection/fixtures/delete-edge-from-connection-plural.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentsDeleteMutation( 2 | $input: CommentsDeleteInput 3 | $connections: [ID!]! 4 | ) { 5 | commentsDelete(input: $input) { 6 | deletedCommentIds @deleteEdge(connections: $connections) 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_reserved_aliases/fixtures/relay_id-alias-with-errors.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment User_fragment on User { 3 | __id: name 4 | } 5 | 6 | fragment Page_fragment on Node { 7 | ... on Page { 8 | __id: author { 9 | name 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/flatten/fixtures/flattens-inside-plural.graphql: -------------------------------------------------------------------------------- 1 | query TestQuery($id: ID!) { 2 | flattened: usernames(names: []) { 3 | ... on Actor { 4 | name 5 | } 6 | } 7 | notFlattened: usernames(names: []) { 8 | ... on User { 9 | lastName 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/relay_actor_change/fixtures/actor-change-pluarl.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment TestFragment on Query { 4 | usernames(names: ["Antonio"]) @fb_actor_change { 5 | ...ForActorChange 6 | } 7 | } 8 | 9 | fragment ForActorChange on Actor { 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/subscription_transform/fixtures/subscription_transform_noop_no_spread.graphql: -------------------------------------------------------------------------------- 1 | # noop because this expects a fragment spread 2 | subscription CommentCreateSubscription( 3 | $input: CommentCreateSubscriptionInput! 4 | ) { 5 | commentCreateSubscribe(input: $input) { 6 | __typename 7 | } 8 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_directive/fixtures/resolver-scalar.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query resolverQuery @updatable { 3 | resolver_field 4 | } 5 | 6 | # %extensions% 7 | 8 | extend type Query { 9 | resolver_field: Boolean @relay_resolver(import_path: "ResolverModule") 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_in_condition.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Query { 3 | node(id: "4") { 4 | ...Updatable_node @skip(if: true) 5 | } 6 | } 7 | 8 | fragment Updatable_node on Node @updatable { 9 | __id 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_deprecated_fields/fixtures/deprecated_scalar_field_within_linked_field.graphql: -------------------------------------------------------------------------------- 1 | query Foo { 2 | me { 3 | author { 4 | name 5 | some_old_field 6 | } 7 | } 8 | } 9 | %extensions% 10 | extend type User { 11 | some_old_field: String @deprecated 12 | } 13 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_global_variables/fixtures/fragment-with-undefined-variable.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | query QueryWithUnusedVariable { 3 | node { 4 | ...UserFragment 5 | } 6 | } 7 | 8 | fragment UserFragment on User { 9 | name @include(if: $shouldIncludeName) 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_relay_directives/fixtures/unmasked-spread-with-directive.invalid.graphql: -------------------------------------------------------------------------------- 1 | #expected-to-throw 2 | fragment UserProfile on User { 3 | profilePicture { 4 | ...PhotoFragment @relay(mask: false) 5 | } 6 | } 7 | 8 | fragment PhotoFragment on Image @inline { 9 | uri 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/actor-change.graphql: -------------------------------------------------------------------------------- 1 | fragment ActorFragment on User { 2 | name 3 | profilePicture { 4 | uri 5 | width 6 | height 7 | } 8 | } 9 | 10 | fragment ViewerFragment on Viewer { 11 | actor @fb_actor_change { 12 | ...ActorFragment 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_flow/fixtures/required-bubbles-up-to-mutation-response.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentCreateMutation($input: CommentCreateInput!) { 2 | commentCreate(input: $input) @required(action: LOG) { 3 | comment @required(action: LOG) { 4 | id @required(action: LOG) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/custom-scalar-type-import.graphql: -------------------------------------------------------------------------------- 1 | query Viewer($params: JSON) { 2 | viewer { 3 | actor { 4 | ... on User { 5 | profilePicture2(additionalParameters: $params) { 6 | __typename 7 | } 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/directive-on-arg-def.graphql: -------------------------------------------------------------------------------- 1 | enum RequiredFieldAction { 2 | NONE 3 | LOG 4 | THROW 5 | } 6 | 7 | directive @required(action: RequiredFieldAction! @static) on FIELD 8 | 9 | directive @static on ARGUMENT_DEFINITION 10 | 11 | type Query { 12 | foo: String 13 | } 14 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.4.1/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.5.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.6.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.6.1/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.6.2/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v1.7.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v2.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v3.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v4.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v5.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v6.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v7.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v7.1.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v8.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v9.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v9.1.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir-validations/tests/validate_selection_conflict/fixtures/same-alias-nested.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | me { 4 | profile_picture { 5 | same_alias: width 6 | } 7 | } 8 | me { 9 | profile_picture { 10 | same_alias: height 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir-validations/tests/validate_selection_conflict/fixtures/same-alias-under-different-inline-fragments.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery { 3 | me { 4 | ... on User { 5 | same_alias: lastName 6 | } 7 | ... on Actor { 8 | same_alias: name 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/graphql-ir/tests/parse/fixtures/argument_definitions_directives_invalid_syntax.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | fragment InvalidArgumentDirectives on User 4 | @argumentDefinitions( 5 | # should have @ 6 | invalid_syntax: { type: "ID", directives: ["live_query"] } 7 | ) { 8 | __typename 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/basic_inline_fragments.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment on Query { 2 | my_alias: node(id: $id) { 3 | id 4 | ... { 5 | id 6 | } 7 | ... on User { 8 | name 9 | likers(first: $count) { 10 | count 11 | } 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /compiler/crates/graphql-text-printer/tests/print/fixtures/fragment_variables.graphql: -------------------------------------------------------------------------------- 1 | fragment MyFragment($some_arg: String, $another_arg: [Int]!) on Query { 2 | my_alias: node(id: $id) { 3 | id 4 | ... on User { 5 | name 6 | likers(first: $count) { 7 | count 8 | } 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/linked-handle-field.graphql: -------------------------------------------------------------------------------- 1 | query linkedHandleField_LinkedHandleFieldQuery($id: ID!) { 2 | node(id: $id) { 3 | ... on User { 4 | friends(first: 10) @__clientField(handle: "clientFriends") { 5 | count 6 | } 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /compiler/crates/relay-compiler/tests/compile_relay_artifacts/fixtures/unused_fragment_argdef_invalid_suppression_arg.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment unusedFragmentArgdefInvalidSuppressionArg on User @argumentDefinitions( 3 | size: { type: "Int", unusedLocalVariable_DEPRECATED: false } 4 | ) { 5 | __typename 6 | } 7 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/assignable_fragment_spread/fixtures/skipped-assignable-fragment-spread.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | query TestQuery($skip: Boolean!) { 3 | me { 4 | ...Assignable_user @skip(if: $skip) 5 | } 6 | } 7 | 8 | fragment Assignable_user on User @assignable { 9 | __typename 10 | } -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/disallow_reserved_aliases/fixtures/id-alias.expected: -------------------------------------------------------------------------------- 1 | ==================================== INPUT ==================================== 2 | fragment User_fragment on User { 3 | id: id 4 | __typename 5 | } 6 | ==================================== OUTPUT =================================== 7 | OK 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/provided_variable_fragment_transform/fixtures/single_fragment.graphql: -------------------------------------------------------------------------------- 1 | fragment SingleFragment on User 2 | @argumentDefinitions(profilePictureScale: {type: "[Int]", provider: "profilePictureScaleProvider"}) 3 | { 4 | profilePicture(size: $profilePictureScale) { 5 | uri 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_concrete_in_different_concrete.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Query { 3 | story { 4 | ...Updatable_comment 5 | } 6 | } 7 | 8 | fragment Updatable_comment on Comment @updatable { 9 | __id 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_concrete_in_matching_abstract.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Query { 3 | node { 4 | ...Updatable_comment 5 | } 6 | } 7 | 8 | fragment Updatable_comment on Comment @updatable { 9 | __id 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/updatable_fragment_spread/fixtures/updatable_fragment_spread_concrete_in_non_matching_abstract.invalid.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | fragment Foo on Query { 3 | node { 4 | ...Updatable_query 5 | } 6 | } 7 | 8 | fragment Updatable_query on Query @updatable { 9 | __id 10 | } 11 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/FragmentWithValidName.ios.graphql: -------------------------------------------------------------------------------- 1 | fragment FragmentWithValidNameIos_fragment on User { 2 | name 3 | } 4 | 5 | fragment FragmentWithValidNameIosFragment on User { 6 | name 7 | } 8 | 9 | fragment FragmentWithValidNameIos on User { 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-transforms/tests/validate_module_names/fixtures/FragmentWithValidName.other-suffix.graphql: -------------------------------------------------------------------------------- 1 | fragment FragmentWithValidName_fragment on User { 2 | name 3 | } 4 | 5 | fragment FragmentWithValidNameFragment on User { 6 | name 7 | } 8 | 9 | fragment FragmentWithValidName on User { 10 | name 11 | } 12 | -------------------------------------------------------------------------------- /compiler/crates/relay-typegen/tests/generate_typescript/fixtures/required-bubbles-up-to-mutation-response.graphql: -------------------------------------------------------------------------------- 1 | mutation CommentCreateMutation($input: CommentCreateInput!) { 2 | commentCreate(input: $input) @required(action: LOG) { 3 | comment @required(action: LOG) { 4 | id @required(action: LOG) 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /compiler/crates/schema/tests/build_schema/fixtures/extend-interface-before-define.graphql: -------------------------------------------------------------------------------- 1 | # expected-to-throw 2 | 3 | schema { 4 | query: Query 5 | } 6 | 7 | type Query { 8 | foo: MyType 9 | } 10 | 11 | extend type MyType { 12 | will_this_crash: Int 13 | } 14 | 15 | type MyType { 16 | is_this_cool: Boolean 17 | } 18 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v10.0.0/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | -------------------------------------------------------------------------------- /website/versioned_docs/version-v10.0.1/Modern-ConversionScripts.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: conversion-scripts 3 | title: Conversion Scripts 4 | original_id: conversion-scripts 5 | --- 6 | We built a few scripts to help you with the conversion process. Check them out at [github.com/relayjs/relay-codemod](https://github.com/relayjs/relay-codemod). 7 | --------------------------------------------------------------------------------