material ui make theme code example
Example 1: themein material ui
import { createMuiTheme } from '@material-ui/core/styles';
import purple from '@material-ui/core/colors/purple';
import green from '@material-ui/core/colors/green';
const theme = createMuiTheme({
palette: {
primary: purple,
secondary: green,
},
status: {
danger: 'orange',
},
});
Example 2: material ui change theme
import { createMuiTheme } from '@material-ui/core/styles';
const theme = createMuiTheme({
palette: {
primary: {
main: '#ff4400',
},
secondary: {
light: '#0066ff',
main: '#0044ff',
contrastText: '#ffcc00',
},
},
});