Description
Currently, @mui/icons-material package has a tight dependency on the @mui/material workspace, requiring it as both a peer dependency and dev dependency. This makes it difficult to update and release icons independently from the main Material UI library.
Current State
The @mui/icons-material package only uses two exports from @mui/material:
SvgIcon component (from @mui/material/SvgIcon)
createSvgIcon function (from @mui/material/SvgIcon)
These are used in:
src/icon.d.ts - TypeScript type definitions
src/utils/createSvgIcon.js - Utility for creating icon components
Proposal
Extract the SvgIcon component and createSvgIcon function into a separate, minimal workspace package that @mui/icons-material can depend on. This would allow:
- Independent versioning and release cycles for icons and core Material UI
- Faster updates to the icons library without waiting for full Material UI releases
- Reduced dependency coupling between packages
- Cleaner build and development workflows
Benefits
- Icons can be updated on a quarterly basis without blocking other Material UI changes
- Simpler dependency tree for users who only need icons
- More flexible release management
Alternative Approaches
- Move just the
SvgIcon component to a separate @mui/svg-icon package
- Bundle
SvgIcon directly within @mui/icons-material (though this may cause duplication)
Search keywords:
Description
Currently,
@mui/icons-materialpackage has a tight dependency on the@mui/materialworkspace, requiring it as both a peer dependency and dev dependency. This makes it difficult to update and release icons independently from the main Material UI library.Current State
The
@mui/icons-materialpackage only uses two exports from@mui/material:SvgIconcomponent (from@mui/material/SvgIcon)createSvgIconfunction (from@mui/material/SvgIcon)These are used in:
src/icon.d.ts- TypeScript type definitionssrc/utils/createSvgIcon.js- Utility for creating icon componentsProposal
Extract the
SvgIconcomponent andcreateSvgIconfunction into a separate, minimal workspace package that@mui/icons-materialcan depend on. This would allow:Benefits
Alternative Approaches
SvgIconcomponent to a separate@mui/svg-iconpackageSvgIcondirectly within@mui/icons-material(though this may cause duplication)Search keywords: