Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[code-infra] Rely on @mui/monorepo/.eslintrc #352

Merged
merged 1 commit into from
Apr 26, 2024

Conversation

oliviertassinari
Copy link
Member

@oliviertassinari oliviertassinari commented Apr 21, 2024

Help remove duplication in the codebase.

Inspired me to try the same with the others: mui/mui-x#12864, mui/toolpad#3441.

@oliviertassinari oliviertassinari added the scope: code-infra Specific to the code-infra product label Apr 21, 2024
@michaldudak
Copy link
Member

I don't think this is the best approach going forward. The Core repo should contain rules specific to it, not the shared code. The master eslint config (without project-specific overrides) should be moved to another repo and referenced from there. IMO we should treat @mui/material increasingly more as a Material UI project repository, not the home for all shared configs.

@oliviertassinari
Copy link
Member Author

oliviertassinari commented Apr 22, 2024

The Core repo should contain rules specific to it, not the shared code

@michaldudak I agree, when I look at https://github.com/mui/material-ui/blob/a90032f61a16117ceeda03ec943edd16f2b20dfb/.eslintrc.js#L416, it feels like having this outside of what Base UI imports is better. We should make it clear what's shared config (90% of the file) and Material UI specific (10% of the file).

Now, I haven't seen a lot of cases where it's problematic. Usually when Material UI adds something, if it's specific to himself, it matches a path that MUI X doesn't have.

Also having this would be great in Base UI: https://github.com/mui/mui-x/blob/4b07dfdbf67f5a6798ee71992656f40250124a50/.eslintrc.js#L162

@oliviertassinari oliviertassinari merged commit 4ae7406 into mui:master Apr 26, 2024
16 checks passed
@oliviertassinari oliviertassinari deleted the shared-eslint-config branch April 26, 2024 16:16
@oliviertassinari
Copy link
Member Author

I referenced the idea about splitting the ESLint config to mui/mui-public#213.

michaldudak pushed a commit to michaldudak/base-ui that referenced this pull request Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: code-infra Specific to the code-infra product
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants