Answers for "adding mui theme to index.js"

0

adding mui theme to index.js

import React from 'react';
import { render } from 'react-dom';
import { MuiThemeProvider, createMuiTheme } from '@material-ui/core/styles';
import CssBaseline from "@material-ui/core/CssBaseline";
import Root from './Root';

const theme = createMuiTheme();

function App() {
  return (
    <MuiThemeProvider theme={theme}>
      <React.Fragment>
        <CssBaseline />
        <Root />
      </React.Fragment>
    </MuiThemeProvider>
  );
}

render(<App />, document.querySelector('#app'));
Posted by: Guest on November-28-2019

Code answers related to "adding mui theme to index.js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language