A class that contains static methods for configuring the components, among other things.

Constructors

Properties

Constructors

Properties

configure: ((value: DeepPartial<{
    Form: {
        props: Partial<FormProps<any>>;
        sx: SxSelectorRecord<SxConfig<{
            classes: readonly ["form_input_row", "submit_button"];
        }>> & MuiSxProps;
        transform: ConfigTransform;
    };
    Table: {
        props: Partial<TableProps>;
        sx: SxSelectorRecord<SxConfig<{
            classes: readonly ["table_container", "table", "table_head", "table_body", "table_row", "table_cell"];
        }>> & MuiSxProps;
        transform: ConfigTransform;
    };
}>) => void) = setConfig

Type declaration

    • (value): void
    • Parameters

      • value: DeepPartial<{
            Form: {
                props: Partial<FormProps<any>>;
                sx: SxSelectorRecord<SxConfig<{
                    classes: readonly ["form_input_row", "submit_button"];
                }>> & MuiSxProps;
                transform: ConfigTransform;
            };
            Table: {
                props: Partial<TableProps>;
                sx: SxSelectorRecord<SxConfig<{
                    classes: readonly ["table_container", "table", "table_head", "table_body", "table_row", "table_cell"];
                }>> & MuiSxProps;
                transform: ConfigTransform;
            };
        }>

      Returns void

      Sets the configuration

Set configuration for the components

import {ThemeProvider, createTheme} from '@mui/material'
import Muitils from 'muitils'

const theme = createTheme()

Muitils.configure({
Form: {
sx: {
classes: {
'form_input_row': {
color: 'red'
}
}
},
transform: (component) => (
<ThemeProvider theme={theme}>
{component}
</ThemeProvider>
),
props: {
className: 'test'
}
}
})