Is there anything planned to make emotion compatible with React 19? #3318
-
I am trying to update my codebase to React 19 but I am not able since emotion does not seem to support React 19. Here are the logs for more context: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The current official version of Emotion 11.14.0 doesn't explicitly support React 19, which is causing this issue. The reason npm can't resolve dependencies is because Emotion's peer dependency configuration doesn't explicitly include React 19. npm install react@latest react-dom@latest --legacy-peer-deps However, this approach ignores peer dependency conflicts, which means there's a possibility of additional runtime issues occurring. 😢 |
Beta Was this translation helpful? Give feedback.
The current official version of Emotion 11.14.0 doesn't explicitly support React 19, which is causing this issue. The reason npm can't resolve dependencies is because Emotion's peer dependency configuration doesn't explicitly include React 19.
While the Emotion team is working on improving some type compatibility with React 19, it appears that version 11 won't fully support React 19. The Emotion development team has officially stated that they plan to provide complete compatibility with React 19 in version 12.
If you absolutely need to use React 19 now, you can temporarily use React 19 with Emotion by using the --legacy-peer-deps option