StyleProvider Context missed
See original GitHub issueStyleProvider Context is missed and get all times the default options
<StylesProvider
generateClassName={pageContext.generateClassName}
jss={pageContext.jss}
{...paramsToTheme}
// registry={pageContext.sheetsRegistry}
// jss={pageContext.jss}
// generateClassName={pageContext.generateClassName}
>
<ThemeProvider
// {...paramsToTheme}
theme={pageContext.theme}
// sheetsManager={pageContext.sheetsManager}
>
<CssBaseline />
<ErrorBoundary location={location} history={history}>
<AppWrapper {...this.props} changeTheme={this.changeTheme} />
</ErrorBoundary>
</ThemeProvider>
</StylesProvider>
but the options pass to provider when makestyles get the context the context is other
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (5 by maintainers)
Top Results From Across the Web
StyleProvider Context missed · Issue #15767 · mui/material-ui
StyleProvider Context is missed and get all times the default options. <StylesProvider generateClassName={pageContext.
Read more >How to styling header & button with StyleProvider at the same ...
I want to change background color of header and add custom style property on the button. <Container> <Header /> /*change backgroundColor*/ < ...
Read more >Advanced Usage - styled-components
This way themes themselves can be made contextual. ... This is useful to circumvent a missing ThemeProvider or to override it.
Read more >5 React Material UI Features You Might Have Missed
As a frontend engineer, Material-UI is my favorite styling option for React Components. Its sleek design and elegance made it stand out from ......
Read more >cf-style-provider - npm Package Health Analysis - Snyk
Looks like cf-style-provider is missing a security policy. ... To ensure that everything has the same context and works properly, you should never...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Yes the error is beco use the context is different so is becomes you have different vesions of material ui core and styles package , if you remove the dependencia of styles and only let the core it’s all right if not the core use a self version of styles and you are getting other version in your own code of style provider
Your version strings in your package.json seem off. Please add a lockfile and verify that only a single version of
@material-ui/styles
is installed.