Cómo usar el tema personalizado correctamente con el componente lib que usa Material UI (no quiero envolver con ellos todos los componentes).
import { createMuiTheme } from '@material-ui/core/styles';
const theme = createMuiTheme({ palette: { primary: { main: '#1976d2' }, success: { main: '#4caf50' } }, typography: { fontSize: 16, h3: { fontWeight: 700, fontSize: '2.2rem' }, h4: { fontWeight: 700, fontSize: '1.75rem' }, h5: { fontWeight: 500 }, h6: { fontWeight: 500 } } }) export default theme;Solo tengo un archivo de índice donde exportar todos mis componentes como lo hace lib de costumbre. ¿Cómo puedo envolver todos mis componentes con el tema sin hacerlo en todas partes? ¿O hay una mejor manera de personalizar los estilos?
Puede envolver su archivo App.tsx (o _app.tsx si usa Next.js) en ThemeProvider y proporcionar su tema: https://mui.com/customization/theming/