-
-
Notifications
You must be signed in to change notification settings - Fork 293
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
Material-ui Typography deprecation warnings #19
Comments
@JakubPetriska notistack doesn't use any |
@kubalobo We used to pass variant= But this will be removed in the next release of notistack, since we can mute the warnings using |
@iamhosseindhv I actually am using the new Typography variants. |
Have you tried isolating / commenting out notistack to make sure the warning is comming from notistack? @JakubPetriska If you think it's a notistack issue, please reproduce the warning and provide a link to codesandbox. |
Yes I did and it confirmed that notistack is the issue. Ok I will try to reproduce that and post it here. |
@iamhosseindhv The error can be seen in this codesandbox. It's the minimal |
@JakubPetriska Downloaded the sandbox and I don't get any warning. I'll have an eye on this issue in case more people complained about it. |
The error happens in the sandbox. I didn't try to download it. Why is there a |
To compare material/notistack versions installed under According to docs, "List packages in the global install prefix instead of in the current project." So I was wondering maybe you have different versions of material/notistack installed globally and your working directory. What I just said might be irrelevant to the problem though. |
I don't have either installed globally, which the output of the command you sent confirmed. |
This happens to me too and is notistack for sure... Any news on how to fix? Since this will be fixed on 0.3.8 when this version will be published? |
@pedro-dcc You should not get any warning regarding "Deprecated variants" using current version of notistack, if you have done material-ui migration instructions. @JakubPetriska The reason minimal example gives us deprecation warnings is that we don't use https://github.com/iamhosseindhv/notistack/blob/master/demo/MessageButtons.js#L47 // Avoid material-ui warnings. more info: https://material-ui.com/style/typography/#migration-to-typography-v2
window.__MUI_USE_NEXT_TYPOGRAPHY_VARIANTS__ = true; |
@iamhosseindhv you are wrong. I'm already setting "useNextVariants" to true and the warning still happened. And shows up when I show some notistack snackbar. |
Provide codesandbox @pedro-dcc |
The warning being discussed here no longer appears. I upgraded dependencies in the codepen I provided, the changes can be seen here, and it no longer appears in there either. Unless somebody objects I guess we can close this @iamhosseindhv . |
Thanks for the update @JakubPetriska |
Sorry for coming back so late. I was wrong. I have faced this issue only because I had the snackbar provider outside MuiTheme. After put that inside the warning has gone. Thanks. |
Expected Behavior
No errors should show up.
Current Behavior
Material UI error about using deprecated typography variant is shown.
The text was updated successfully, but these errors were encountered: