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

Deprecate relay-hooks in favour of the built-in hooks #136

Open
2 tasks
kawazoe opened this issue Feb 21, 2023 · 3 comments
Open
2 tasks

Deprecate relay-hooks in favour of the built-in hooks #136

kawazoe opened this issue Feb 21, 2023 · 3 comments

Comments

@kawazoe
Copy link

kawazoe commented Feb 21, 2023

Since it was vaguely discussed in #109 , I thought I'd create an issue to guage interest and track progress toward switching over to the built-in hooks.

With relay well into v14 v15 and pushing for suspense and error boundaries, I expect people will want to use this new feature rather quickly. There are already three people who expressed desire for this feature in other issues.

I might be able to find time to help with this process if you're interested.

  • Update offline hooks to use built-ins (includes API changes)
  • Update suspense exemple (still on relay v9)
@morrys
Copy link
Owner

morrys commented Mar 7, 2023

we could think of managing a new library, with the official relay dependency, in a separate branch as I did for the relay-forms library

https://github.com/morrys/relay-forms#build-forms-in-react-with-relay

relay-hooks-offline branch: release new relay-hooks-offline library version 7.0.0 with relay-hooks dependency

branch master: release react-relay-offline library v7.0.0 (breaking change) with react-relay dependency

@kawazoe
Copy link
Author

kawazoe commented Mar 11, 2023

This sounds like a good idea. Did you do any investigation on the update already? Do you know anything needs to be done to support v14+ in term of runtime compatibility (anything outside of hooks)?

@morrys
Copy link
Owner

morrys commented Mar 20, 2023

To adjust for react-relay, it should be enough to remove all non-concurrent hooks, replace the dependency and a small fix in useLazyLoadQuery

While, to adapt to relay 14+ it must be verified that some compatibility in relay-offline has not been broken

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

No branches or pull requests

2 participants