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] Widen eslint file patterns #44148

Merged
merged 5 commits into from
Oct 21, 2024
Merged

Conversation

Janpot
Copy link
Member

@Janpot Janpot commented Oct 18, 2024

Widen javascript/typescript rules to all possible extensions. Avoids situations like #44143 (comment)

Question for @mui/docs-infra: what with material-ui/no-hardcoded-labels, it applies only to js files and in many ts files there are violations. Should we fix those cases? Or remove the rule altogether?

@Janpot Janpot added the scope: code-infra Specific to the core-infra product label Oct 18, 2024
@mui-bot
Copy link

mui-bot commented Oct 18, 2024

Netlify deploy preview

https://deploy-preview-44148--material-ui.netlify.app/

Bundle size report

No bundle size changes (Toolpad)
No bundle size changes

Generated by 🚫 dangerJS against afce056

{
files: ['docs/data/base/components/modal/UseModal.js'],
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Too fine grained, moving this into the file itself

@@ -380,6 +368,13 @@ module.exports = /** @type {Config} */ ({
{
files: ['packages/*/src/**/*.tsx'],
excludedFiles: '*.spec.tsx',
rules: {
'react/prop-types': 'off',
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one got lumped in with the one below, but should only apply to tsx files

@Janpot Janpot changed the title [code-infra] expand eslint [code-infra] Widen eslint file patterns Oct 18, 2024
@Janpot Janpot marked this pull request as ready for review October 18, 2024 16:43
@Janpot Janpot requested a review from a team October 18, 2024 16:43
@alexfauquette
Copy link
Member

Question for @mui/docs-infra: what with material-ui/no-hardcoded-labels, it applies only to js files and in many ts files there are violations. Should we fix those cases? Or remove the rule altogether?

I think it's for enforcing translation of docs component which were initially only written in JS.

Could you open a distinct PR to enable it also on ts files. I will give a look to fix what's needed

Copy link
Member

@LukasTy LukasTy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. 👍

@Janpot Janpot merged commit ff14f9e into mui:master Oct 21, 2024
22 checks passed
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 core-infra product
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants