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

loading property doesn't change with autosubscribe and no explicit notifyOnNetworkStatusChange: true #248

Open
danielvanmil opened this issue Jun 20, 2022 · 3 comments · May be fixed by #287
Labels
bug Something isn't working

Comments

@danielvanmil
Copy link

danielvanmil commented Jun 20, 2022

Package

@apollo-elements/core 2.1.2
@apollo-elements/lit-apollo 5.0.3
@apollo/client 3.5.9

Description

  • When I use ApolloQueryController with implicit autoscubscribe with lit-element and render the controller's loading property it doesn't change
  • When I add the explicit option "notifyOnNetworkStatusChange: true" it does
  • When executing a query explicitly by "executeQuery()" it the loading property does change

Steps To Reproduce

  • Create an Apollo element with an ApolloQueryController (autosubscribe by default)
  • query loads and loading property indicates loading correctly
  • change the variables so the query reloads
  • watch the loading property of the query, it doesn't change

Expected Behavior

loading property changes

Actual Behavior

loading property only changes on first load

Note

When the notifyOnNetworkStatusChange is set to true on the query options the loading property DOES change all the time.
If not it only changes on initial loading

Browser and Version

Chrome 102

@danielvanmil danielvanmil added the bug Something isn't working label Jun 20, 2022
@bennypowers
Copy link
Member

please create a reproduction

@danielvanmil
Copy link
Author

added reproduction

@bennypowers bennypowers linked a pull request Jun 1, 2023 that will close this issue
@bennypowers
Copy link
Member

can you try with the branch on #287, please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants