Deprecation warnings when on `4.11.4`
See original GitHub issue- The issue is present in the latest release.
- I have searched the issues of this repository and believe that this is not a duplicate.
Current Behavior 😯
When running my application using 4.11.4
I get the following “warnings” in my browsers console log which are actually formatted as console.error
vendor.js:41443 Material-UI: the createMuiTheme function was renamed to createTheme.
You should use `import { createTheme } from '@material-ui/core/styles'`
createMuiTheme @ vendor.js:41443
vendor.js:40734 Material-UI: The `fade` color utility was renamed to `alpha` to better describe its functionality.
You should use `import { alpha } from '@material-ui/core/styles'`
fade @ vendor.js:40734
vendor.js:98306 Warning: Failed prop type: Material-UI: `fontSize="default"` is deprecated. Use `fontSize="medium"` instead.
at Icon (http://localhost:4200/vendor.js:18664:23)
at WithStyles (http://localhost:4200/vendor.js:53805:31)
at O (http://localhost:4200/vendor.js:101672:21572)
at DotIcon (http://localhost:4200/vendor.js:782:24)
at div
at ListItemIcon (http://localhost:4200/vendor.js:22297:23)
at WithStyles (http://localhost:4200/vendor.js:53805:31)
at span
at li
at ButtonBase (http://localhost:4200/vendor.js:8536:22)
at WithStyles (http://localhost:4200/vendor.js:53805:31)
at ListItem (http://localhost:4200/vendor.js:21935:33)
at WithStyles (http://localhost:4200/vendor.js:53805:31)
at O (http://localhost:4200/vendor.js:101672:21572)
at DotListItem (http://localhost:4200/vendor.js:2739:25)
at ul
at List (http://localhost:4200/vendor.js:21693:24)
at WithStyles (http://localhost:4200/vendor.js:53805:31)
at O (http://localhost:4200/vendor.js:101672:21572)
at DotList (http://localhost:4200/vendor.js:2686:25)
at Resources
at div
at O (http://localhost:4200/vendor.js:101672:21572)
at div
at O (http://localhost:4200/vendor.js:101672:21572)
at div
at O (http://localhost:4200/vendor.js:101672:21572)
at Home (http://localhost:4200/main.js:14034:111)
at DestinationsProvider (http://localhost:4200/main.js:15901:3)
at Route (http://localhost:4200/vendor.js:95090:29)
at PrivateRoute (http://localhost:4200/main.js:12100:89)
at Switch (http://localhost:4200/vendor.js:95296:29)
at Routes
at section
at main
at O (http://localhost:4200/vendor.js:101672:21572)
at div
at O (http://localhost:4200/vendor.js:101672:21572)
at MainLayout (http://localhost:4200/main.js:12474:3)
at SidebarProvider (http://localhost:4200/main.js:16512:3)
at div
at O (http://localhost:4200/vendor.js:101672:21572)
at App (http://localhost:4200/main.js:11958:78)
at Ge (http://localhost:4200/vendor.js:101672:19082)
at ThemeProvider (http://localhost:4200/vendor.js:52508:24)
at StylesProvider (http://localhost:4200/vendor.js:52321:24)
at DotThemeProvider (http://localhost:4200/vendor.js:4735:23)
at Router (http://localhost:4200/vendor.js:94719:30)
at BrowserRouter (http://localhost:4200/vendor.js:94325:35)
at KeycloakProvider (http://localhost:4200/vendor.js:55767:51)
at PermissionsProvider (http://localhost:4200/main.js:12056:3)
Expected Behavior 🤔
There should be no console errors for deprecation warnings… EVER. That’s what console.warn
is for.
Context 🔦
We are building a web application, our console log shouldn’t be littered with “errors” that are actually deprecation warnings.
Your Environment 🌎
`npx @material-ui/envinfo`
Google Chrome, Firefox, Brave
System:
OS: macOS 11.4
Binaries:
Node: 15.11.0 - /usr/local/bin/node
Yarn: 1.22.10 - /usr/local/bin/yarn
npm: 7.6.0 - /usr/local/bin/npm
Browsers:
Chrome: 91.0.4472.114
Edge: Not Found
Firefox: 86.0.1
Safari: 14.1.1
npmPackages:
@material-ui/core: 4.12.1
@material-ui/lab: 4.0.0-alpha.60
@material-ui/styles: 4.11.4
@material-ui/system: 4.12.1
@material-ui/types: 5.1.0
@material-ui/utils: 4.11.2
@types/react: 16.9.56 => 16.9.56
react: 17.0.1 => 17.0.1
react-dom: 17.0.1 => 17.0.1
styled-components: 5.2.1 => 5.2.1
typescript: ~4.0.3 => 4.0.7
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Deprecation warnings when on `4.11.4` · Issue #27265 - GitHub
The issue is present in the latest release. I have searched the issues of this repository and believe that this is not a...
Read more >4.10.4. Puppet Issues — SIMP 6.6.0-Alpha documentation
This will disable all deprecation warnings. If new settings are deprecated in future releases, you will not see warnings about them. This is...
Read more >Deprecating static attributes in factory_bot 4.11 - Thoughtbot
Their deprecation will come with a rubocop-rspec Cop to automatically replace with dynamic ... Deprecation warnings aren't exactly fun.
Read more >4.11.4 - Release Status
4.11.4. Download the installer for your operating system or run ... Bug 2073113: do not report docker conf deprecation warning when the docker...
Read more >Assert in junit.framework has been deprecated - Stack Overflow
As it seems the Assert class has been moved from junit.framework to org.junit.Assert in JUnit 4.0 - you can use that instead, it's...
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
That did it!
package.json
These deprecation errors are causing us some problems too. We have a shared
ThemeProvider
used by many projects that is now generating an “error” because it’s usingcreateMuiTheme
. Downgrading to4.11
doesn’t work because of the@material-ui/system
issue and we’re all usingnpm 6
whereresolutions
is not an option.Short of us releasing a new theme that forces a dependency on 4.12 (and having to update a ton of projects) how can we hide these warnings? The noise of these warnings is confusion users, especially when running tests.