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

@emotion/react ThemeProvider not working #1111

Open
marcoamonteiro opened this issue Jun 8, 2021 · 2 comments
Open

@emotion/react ThemeProvider not working #1111

marcoamonteiro opened this issue Jun 8, 2021 · 2 comments

Comments

@marcoamonteiro
Copy link

To reproduce:

Simple example from the rebass documentation and create-react-app: https://rebassjs.org/getting-started

import React from 'react';
import './App.css';
import {Heading} from 'rebass'
import { ThemeProvider } from '@emotion/react'
import styled from '@emotion/styled'

const theme = ...

function App() {
  return (
      <ThemeProvider theme={theme}>
        <div className="app">
          <Heading fontSize={7}>Hello</Heading>
        </div>
      </ThemeProvider>
  );
}

Expected behavior:

Theme is not applied to Rebass components

Environment information:

  • react version: 4.0
  • @emotion/react version: 11.4
@rjerue
Copy link

rjerue commented Jun 12, 2021

Instead of @emiton/react, emotion-theming": "^10.0.27" does work for me, though I agree the behavior is not intended/poor.

Rebass seems dead though :(

@anujmv
Copy link

anujmv commented Feb 2, 2022

Same issue with theme-ui provider, styles are not being applied. works with older version of theme-ui

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

3 participants