question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Material theme doesn't work with 0.15 version of material-ui

See original GitHub issue

Because Material-UI changed Colors file:

so before you should did:

import Colors from 'material-ui/lib/styles/colors'; 
//use somewhere
Colors.darkBlack

but now:

import { darkBlack } as Colors from 'material-ui/lib/styles/colors';.

you can check it here https://github.com/callemall/material-ui/pull/2825

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
yannickschuchmanncommented, Mar 27, 2016

I just tried to update material-ui but since v0.14.3 I get:

Uncaught Error: Invariant Violation: Element type is invalid: 
expected a string (for built-in components) or a class/function but got: undefined

This may happen because of a broken import statement. Unfortunately I haven’t found it yet. v0.14.2 works like a charm for me… I checked the changelog of 0.14.3… no idea

0reactions
lynndylanhurleycommented, Jul 15, 2016

Working as of 0.0.3-beta6.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why the theme doesn't work in Material-UI? - Stack Overflow
Your code doesn't work because you're using usesStyles hook in a root component ( App ) that is not wrapped inside ThemeProvider ....
Read more >
Troubleshooting - Material UI - MUI
This document covers known issues and common problems encountered when migrating from Material UI v4 to v5.
Read more >
Colors are not working on Raised Button · Issue #2676 - GitHub
I am trying to get the colors shown in the material-ui.com RaisedButton demo but my ... It doesn't work on Chrome 50, React...
Read more >
Troubleshooting - Material Theme UI Documentation
Q: I've updated the IDE/plugin to a new version, and now I get an error about the plugin failing to initialize? A: It...
Read more >
@material-ui/styles | Yarn - Package Manager
Material UI v4 doesn't receive active development since September 2021. See the guide https://mui.com/material-ui/migration/migration-v4/ to upgrade to v5.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found