Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Material-ui getMuiTheme missing after upgrading from 0.9 to 1

Tags:

material-ui

Uncaught Error: Module build failed: Error: ENOENT: no such file or directory, open '/Users/leongaban/projects/go/src/github.com/pizzahutdigital/mythor/node_modules/material-ui/styles/getMuiTheme.js'

Been using the theme, style and components from http://www.material-ui.com/#/ to build a app at the moment.

However I need the Grid component which doesn't exist in 0.9 but exists here in the 1.0 beta https://material-ui-next.com/layout/grid/

like image 989
Leon Gaban Avatar asked Oct 30 '17 16:10

Leon Gaban


1 Answers

getMuiTheme has been replaced by createMuiTheme in 'material-ui/styles'

This worked for me : import { MuiThemeProvider, createMuiTheme } from 'material-ui/styles';

See Documentation -> https://github.com/callemall/material-ui/blob/v1-beta/docs/src/pages/customization/themes.md

(Docs on master and v1-beta differ, be sure to check out the v1 branch docs)

like image 138
ted Avatar answered Oct 09 '22 04:10

ted