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

[charts] Fix eslint for react compiler #13444

Merged
merged 2 commits into from
Jun 13, 2024

Conversation

alexfauquette
Copy link
Member

@alexfauquette alexfauquette commented Jun 11, 2024

Not sure it's the best way to fix warnings about no side effect, but it works 😇

@alexfauquette alexfauquette added the component: charts This is the name of the generic UI component, not the React module! label Jun 11, 2024
@mui-bot
Copy link

mui-bot commented Jun 11, 2024

Deploy preview: https://deploy-preview-13444--material-ui-x.netlify.app/

Generated by 🚫 dangerJS against 117d0b9

@alexfauquette alexfauquette requested a review from JCQuintas June 11, 2024 13:59
Copy link
Member

@JCQuintas JCQuintas left a comment

Choose a reason for hiding this comment

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

Smart move changing the warnedOnce into the closure 👍

@@ -0,0 +1,17 @@
export function buildWarning(
Copy link
Member

Choose a reason for hiding this comment

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

I would probably just rename it to buildOneTimeWarning or buildWarningOnce

Copy link
Member Author

Choose a reason for hiding this comment

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

It's a common piece of code we duplicate in each package.

Was introduced mostly to avoid code duplication in the data grid. We could do the renaming but in that case, would require to do it in all packages

Copy link
Member

Choose a reason for hiding this comment

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

up to you, doesn't matter much 😅

should we eventually have a shared X package? shouldn't be too hard to accomplish

Copy link
Member

Choose a reason for hiding this comment

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

should we eventually have a shared X package?

This has been discussed quite recently
I feel like we are only waiting for a use-case and someone to own the creation of the new package 😆

@joserodolfofreitas @cherniavskii if you are OK, we can create it

Copy link
Member

Choose a reason for hiding this comment

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

Agreed, we need a shared utils package 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: charts This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants