I am working on a project with lots of traffic ion regards to commits. My thinking was the best way to go about this migration would be to start with this guide https://mui.com/guides/migration-v4/ and basically install the new packages, run code mods, then have the two version material ui 4 and MUI5 living side by side while components were refactored one by one. This would require keeping out uses of createStyles and makeStyles. However I am running into a problem.
In the code below, theme is undefined:
const useStyles = makeStyles<Theme>(
(theme) =>
createStyles({
...
drawer: {
zIndex: theme.zIndex.drawer,
...
Is there a way to have material ui 4 and MUI5 living together temporarily? If so, why would theme be undefined in this case?