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

Warning: Material-UI: theme.spacing.unit usage has been deprecated. #676

Open
bbtimx opened this issue Jun 6, 2019 · 8 comments
Open

Warning: Material-UI: theme.spacing.unit usage has been deprecated. #676

bbtimx opened this issue Jun 6, 2019 · 8 comments

Comments

@bbtimx
Copy link

bbtimx commented Jun 6, 2019

MUI-datatables works like expected but throw an error message.

Expected Behavior

No error message.

Current Behavior

Error message:

Warning: Material-UI: theme.spacing.unit usage has been deprecated.
It will be removed in v5.
You can replace `theme.spacing.unit * y` with `theme.spacing(y)`.

Steps to Reproduce (for bugs)

  1. Create table like this example: https://github.com/gregnb/mui-datatables/blob/master/examples/simple/index.js
  2. Check one checkbox

Your Environment

Tech Version
Material-UI 4.0.1
MUI-datatables 2.2.0
React 16.8.6
browser Chrome 74.0.3729.169
OS Windows 10
@Diazole
Copy link
Contributor

Diazole commented Jun 6, 2019

Material-UI v4 isn't supported right now, stay on 3.

@bbtimx
Copy link
Author

bbtimx commented Jun 6, 2019

When it will be ready?

@gabrielliwerant
Copy link
Collaborator

@bbtimx Unfortunately, I don't have a good timeline for this at the moment, but it is on my radar, as a lot of people have been asking for it. There are more serious issues that require handling first, but I will turn to upgrading once those are resolved.

@PizzaBrandon
Copy link

@gabrielliwerant Would you be open to a PR for upgrading to Material 4? I just upgraded it locally and it wasn't too painful. It did require updating a number of deps, but all tests pass, spot check of examples work, and the docs still work.

@gabrielliwerant
Copy link
Collaborator

@PizzaBrandon I think I'd like to hold off for a little while longer, as I'm thinking that such an upgrade should come with a bump to the major release version, as it will be difficult to guarantee that there is no breakage. I'd like to squeeze in a few more minor releases before that point, but the plan is definitely to move to v4 at some point, so I won't forget. Or if you like, feel free to ping me about it again in a few weeks. ;)

@PizzaBrandon
Copy link

@gabrielliwerant I agree that this should definitely be treated as a breaking change that should be published as a new major. I would not expect installations using v3 to work correctly after this update.

That said, if the update was maintained in a separate branch and published to npm under a next tag, rather than the default of latest, it would allow the upgrade to happen now with the temporary cost of maintaining two branches until it's ready to be the "real" version. If you take a look at my fork's branch, you'll see I was able to make the update without affecting the logic of the table code itself, making pulling up patches easier.

@PizzaBrandon
Copy link

And, of course, I offer to help maintain that branch at least until it makes it to the live version so it's not an extra burden for you.

@gabrielliwerant
Copy link
Collaborator

@PizzaBrandon understood, let me think about it. It might indeed be a strain on my already limited time. I also think a week or so would not be too long to wait to avoid the overhead of a separate next version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants