Skip to content
This repository has been archived by the owner on Apr 13, 2023. It is now read-only.

package.json devDependencies for React outdated? #2792

Closed
rsokz opened this issue Feb 11, 2019 · 8 comments
Closed

package.json devDependencies for React outdated? #2792

rsokz opened this issue Feb 11, 2019 · 8 comments

Comments

@rsokz
Copy link

rsokz commented Feb 11, 2019

Intended outcome:

An error is stated when trying to use React hooks:

Hooks can only be called inside the body of a function component.

I believe the cause may be react & react-dom devDependency mismatch.

Actual outcome:

Thanks to @ryancogswell for the catch.

The devDependencies in package.json have React listed as: 16.5.2

"react": "16.5.2", "react-dom": "16.8.1"

This may be causing an issue with React hooks.

How to reproduce the issue:

Open package.json

Possibly related issue: https://github.com/facebook/react/issues/14823

Version

  • apollo-client@2.4.12
  • react-apollo@2.4.1
@sapkra
Copy link

sapkra commented Mar 9, 2019

I created a PR, but the builds are failing. Maybe someone can help with the breaking changes. 😉

@MitchTalmadge
Copy link

This is breaking my stuff too. Hope we see an update soon.

@sapkra
Copy link

sapkra commented Mar 15, 2019

They commented my PR that they are working on it.
I'm also hoping that the update will come soon.

@rosskevin
Copy link
Contributor

PR #2892 is open and tracking the changes needed to update react.

@djamaile
Copy link

Is there a workaround for this?

@blakedietz
Copy link

Bump, is there a workaround for this?

@sandorfr
Copy link

Same issue here :( quite desperate to find a workaround.

@sapkra
Copy link

sapkra commented Jun 16, 2019

I think there is no other solution than waiting for version 3.0.0. I think it will not take that long anymore.
See these two comments:
#2892 (comment)
#2539 (comment)

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

No branches or pull requests

7 participants