Skip to content

Commit

Permalink
[DatePicker] Fix codesandbox demo (mui#19926)
Browse files Browse the repository at this point in the history
  • Loading branch information
netochaves authored and EsoterikStare committed Mar 30, 2020
1 parent 5e797e9 commit eaafc6d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
5 changes: 2 additions & 3 deletions docs/src/modules/utils/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,8 @@ function getDependencies(raw, options = {}) {
'@material-ui/styles': 'latest',
'@material-ui/system': 'latest',
'@material-ui/utils': 'latest',
'date-fns': 'next',
jss: 'next',
'jss-plugin-template': 'next',
// TODO: remove once @material-ui/pickers v4 is released.
'@date-io/date-fns': 'v1',
};

const re = /^import\s'([^']+)'|import\s[\s\S]*?\sfrom\s+'([^']+)/gm;
Expand Down
6 changes: 3 additions & 3 deletions docs/src/modules/utils/helpers.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ import { MuiPickersUtilsProvider, TimePicker, DatePicker } from '@material-ui/pi
`;

assert.deepEqual(getDependencies(source), {
'date-fns': 'next',
'@date-io/date-fns': 'latest',
'date-fns': 'latest',
'@date-io/date-fns': 'v1',
'@material-ui/pickers': 'latest',
'@material-ui/core': 'latest',
'prop-types': 'latest',
Expand Down Expand Up @@ -115,7 +115,7 @@ import {
`;

assert.deepEqual(getDependencies(source), {
'date-fns': 'next',
'date-fns': 'latest',
'@material-ui/pickers': 'latest',
react: 'latest',
'react-dom': 'latest',
Expand Down

0 comments on commit eaafc6d

Please sign in to comment.