Skip to content

Conversation

rpgjarman
Copy link

@rpgjarman rpgjarman commented Oct 7, 2025

Fixes #46586

Summary

Added documentation for Vite/Vitest configuration when using styled-components with MUI v7+, addressing ESM/CJS compatibility issues.

Changes

  • Added new "Configuration with Vite and Vitest" section
  • Documented two approaches: fallbackCJS (simpler) and inline dependencies (faster)
  • Included performance notes and best practices based on community feedback in the issue thread

Related Issues

@rpgjarman
Copy link
Author

I've submitted a PR to add the Vite/Vitest configuration to the styled-components documentation.

The documentation now includes both the fallbackCJS and inline dependency options discussed in this thread, with notes on performance differences.

@mui-bot
Copy link

mui-bot commented Oct 7, 2025

Netlify deploy preview

Bundle size report

Bundle Parsed size Gzip size
@mui/material 0B(0.00%) 0B(0.00%)
@mui/lab 0B(0.00%) 0B(0.00%)
@mui/system 0B(0.00%) 0B(0.00%)
@mui/utils 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against c80f0de

@zannager zannager added docs Improvements or additions to the documentation. scope: system The system, the design tokens / styling foundations used across components. eg. @mui/system with MUI integration: vite labels Oct 7, 2025
@zannager zannager requested a review from siriwatknp October 7, 2025 13:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation. integration: vite scope: system The system, the design tokens / styling foundations used across components. eg. @mui/system with MUI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Mui with styled-components and Vite/Vitest is not working since v7

3 participants