facebook / facebook/relay

No validation that an @refetchable queryName is not the name of a fragment

Open
#4,894 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Rust
Stars
19k
Forks
1.9k
PR merge metrics
No merged PRs in 30d

Description

* If a @refetchable fragment has a queryName which is the name of an existing fragment (say `MyFragment`), then `__generated__/MyFragment.graphql` will be the `ReaderFragment`, and not the `ConcreteRequest`.
* If a persisted queries json file is created (and presumably if the query is persisted to the backend?), then the persisted "query" is actually just the fragments.
* Relay should enforce that `queryName` is globally unique. (Presumably there can be collisions with other query names, too, didn't check)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.