Skip to content

Commit c1380d2

Browse files
authored
Merge pull request #1163 from rvsia/addMigrationGuideMUI5
Add migration guide for MUI5
2 parents 0148cc0 + e9c411e commit c1380d2

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

packages/react-renderer-demo/src/pages/provided-mappers/mui-component-mapper.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,47 @@ MUI mapper provides an option to validate a field when the component is mounted.
3636

3737
This field will show the error immediately.
3838

39+
## Migration to version 5
40+
41+
MaterialUI (now known just as MUI) recently released a version 5 that introduces a lot of new features and some breaking changes. Data Driven Forms follows this release with our integration in `mui-component-mapper`. Due to inability to release new version of packages independently, we are going to introduce new changes as a feature release to not disrupt any other mappers. We deeply apologise for any issues it can introduce, but we agreed that this is the best way that won't break any of our current workflows.
42+
43+
### Migration
44+
45+
#### Convert your app to use MUI 5
46+
47+
Please follow [official migration guide](https://mui.com/guides/migration-v4/). *Note: emotion packages are being installed by the mapper itself.*
48+
49+
#### Use beta version of the mapper
50+
51+
Use `3.16.0-v5-beta` version (or check if there is any newer version of v5 version [here](https://www.npmjs.com/package/@data-driven-forms/mui-component-mapper).)
52+
53+
<br />
54+
55+
**And that's it!**
56+
57+
<br />
58+
59+
`mui-component-mapper` itself does not require any additional migration steps!
60+
61+
Only if you are using `date-picker` or `time-picker`, you have to provide `LocalizationProvider` ([read more](https://mui.com/components/time-picker/#localization)), the components themselves do not longer contain it.
62+
63+
### Feedback
64+
65+
If you encounter any issues, please let us know in [our Issues section](https://github.com/data-driven-forms/react-forms/issues).
66+
67+
### What if I do not want to migrate
68+
69+
Please lock your `mui-component-mapper` version in `package.json`:
70+
71+
```diff
72+
# package.json
73+
74+
+ "@data-driven-forms/mui-component-mapper": "^3.15.5",
75+
- "@data-driven-forms/mui-component-mapper": "3.15.5",
76+
```
77+
78+
For any future bug fixes, we will use `3.15` as a base version. (example: next bugfix would be `3.15.6` and these versions will be tagged as `deprecated`.)
79+
80+
In the near future, we will support bugfixes for Material-UI v4 mapper version, but no new features will be implemented. We are open to accept PRs by community. Also, this older version should work with the latest `react-form-renderer` at least until Data Driven Forms version 4 is released.
81+
3982
</DocPage>

0 commit comments

Comments
 (0)