-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[core] Use type imports for theme augmentation #14383
Conversation
Deploy preview: https://deploy-preview-14383--material-ui-x.netlify.app/ |
@flaviendelangle will have more info, but I think it's just a copy/past from the This would explain why the data-grid uses |
It is 😆 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with the change. 👍
I fear that renaming the files could be a niche breaking change.
We could align the approach and rename files on v8.
Or we can refactor the PR to rename files and merge it to next
branch when we start working on it. 🤔
I kind of expect the type generation to have the exact same output. Will test. |
Looks like the difference in output is:
I don't see how either of these could lead to a breaking change for the user. The |
This reverts commit c1d4f56.
It looks like since I made this PR, they have been updated already on master. Closing this for now, X repo satisfies the needs for #14234 now. Up to the team if they want to align further. |
These are importing from a
.d.ts
file, meaning, here is no code to import from, this can confuse build tools such as in #14234. Best to either use.ts
files, or use atype
import.Question: Any reason to not just use
.ts
files? These manual type declarations, while supported, feel a bit like an anti-pattern to me.