Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

handle arguments on inline fragments #3106

Closed
daniloab opened this issue Jun 25, 2020 · 8 comments
Closed

handle arguments on inline fragments #3106

daniloab opened this issue Jun 25, 2020 · 8 comments

Comments

@daniloab
Copy link
Contributor

When I try to pass some arguments to my inline fragment I got (that I imagined would happen)

ERROR:
Variables are not yet supported inside @inline fragments.

My question is whether inline fragments will support variables or any information about it.

@josephsavona
Copy link
Contributor

josephsavona commented Jul 1, 2020

@inline is a relatively newer feature so it's not fully flushed out yet. This is on our backlog but hasn't come up much - especially now that hooks make it easy to use the regular APIs (ie useFragment) as part of composable units of logic. Adding support for variables is on our backlog but not currently high-priority given that there are workarounds. Normally we'd be open to PRs to fix this, but we're actively rewriting the compiler so it will likely be easier to add support for this once the new compiler lands (rough timeframe of later this year).

@stale
Copy link

stale bot commented Dec 25, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Dec 25, 2020
@kleinspire
Copy link

kleinspire commented Jan 18, 2021

Hi @josephsavona

I'm already using useFragment hooks from the experimental tag. Occasionally I need to use fragments outside any React components though and neither @inline or @relay(mask: false) work with @arguments directive. Unfortunately I haven't found a workaround yet. Do you know when it will be implemented?

@stale stale bot removed the wontfix label Jan 18, 2021
@josephsavona
Copy link
Contributor

This hasn't come up a lot so it continues to be lower on our radar. Once we ship the Rust-based compiler to OSS (high on priority list) we will definitely revisit this.

@fdutey
Copy link

fdutey commented Aug 18, 2021

I need it too!!). Very convenient for localized fields in shared fragments ;)

@stale
Copy link

stale bot commented Jan 9, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jan 9, 2022
@thibaultboursier
Copy link

Hello,

Has someone some news about the possibility to provide arguments to inline fragment?
As @webican said, it seems there is no workaround, and it's necessary to have this option when we need to unmask fragment outside of React.

Thanks.

@stale stale bot removed the wontfix label Apr 20, 2022
@josephsavona
Copy link
Contributor

cc @alunyov @kassens — seems like this wouldn't be too hard to support now? Are we open to a PR to enable this?

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

Successfully merging a pull request may close this issue.

5 participants