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

[core] Batch small changes #18041

Merged
merged 17 commits into from
Oct 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ via [Patreon](https://www.patreon.com/oliviertassinari)
via [OpenCollective](https://opencollective.com/material-ui)

<p style="display: flex; justify-content: center; flex-wrap: wrap;">
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group"></a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group" width="100" loading="lazy"></a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.crosswordsolver.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/crosswordsolver/avatar.png" alt="crosswordsolver" title="Crossword Puzzle Solver" width="100" loading="lazy"></a>
</p>

### There is more!
Expand Down
1 change: 0 additions & 1 deletion docs/pages/api/button-base.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ It contains a load of style reset and some focus/ripple logic.
| Name | Type | Default | Description |
|:-----|:-----|:--------|:------------|
| <span class="prop-name">action</span> | <span class="prop-type">ref</span> | | A ref for imperative actions. It currently only supports `focusVisible()` action. |
| <span class="prop-name">buttonRef</span> | <span class="prop-type">ref</span> | | Use that prop to pass a ref to the native button component. |
| <span class="prop-name">centerRipple</span> | <span class="prop-type">bool</span> | <span class="prop-default">false</span> | If `true`, the ripples will be centered. They won't start at the cursor interaction position. |
| <span class="prop-name">children</span> | <span class="prop-type">node</span> | | The content of the component. |
| <span class="prop-name">classes</span> | <span class="prop-type">object</span> | | Override or extend the styles applied to the component. See [CSS API](#css) below for more details. |
Expand Down
2 changes: 2 additions & 0 deletions docs/pages/blog/april-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ But this summary is just scratching the surface. We have accepted 243 commits fr
- Timeline
- Something big 🌈

- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Material-UI is an MIT-licensed open source project. It’s an independent project with ongoing development helped by the support of these awesome [backers](/discover-more/backers/). Please join them ✨.
2 changes: 1 addition & 1 deletion docs/pages/blog/august-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ But this summary is just scratching the surface. We have accepted 193 commits fr

- 🔍 We will keep working on providing ready to use autocomplete, combo box, and multi-select components. We announced it last month but have made little progress so far due to focusing on fixing bugs in existing components. Let's make it happen!

- ❓ Do you want something in specific? Please upvote our GitHub issues, the number of 👍 matters to us.
- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Expand Down
2 changes: 2 additions & 0 deletions docs/pages/blog/july-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ But this summary is just scratching the surface. We have accepted 146 commits fr

![Skeleton](/static/blog/july-2019-update/skeleton.png)

- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Material-UI is an MIT-licensed open source project. It’s an independent project with ongoing development helped by the support of these awesome [backers](/discover-more/backers/). Please join them ✨.
2 changes: 2 additions & 0 deletions docs/pages/blog/june-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ But this summary is just scratching the surface. We have accepted 198 commits fr
You can already [preview it](https://deploy-preview-16455--material-ui.netlify.com/components/rating/).
![Rating](/static/blog/june-2019-update/rating.png)

- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Material-UI is an MIT-licensed open source project. It’s an independent project with ongoing development helped by the support of these awesome [backers](/discover-more/backers/). Please join them ✨.
1 change: 1 addition & 0 deletions docs/pages/blog/march-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Don't worry, it's almost over! We will focus on providing more components once w
- TypeScript demo variants.
- Migration from Classes to Hooks, removal of unnecessary internal components.
- Removal of `findDOMNode()`, support of `StrictMode`, forward of references.
- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Expand Down
2 changes: 2 additions & 0 deletions docs/pages/blog/may-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ If you are an enterprise and are looking for one of the following:

You can contact us at advisory@material-ui.com.

- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Material-UI is an MIT-licensed open source project. It’s an independent project with ongoing development helped by the support of these awesome [backers](/discover-more/backers/). Please join them ✨.
2 changes: 1 addition & 1 deletion docs/pages/blog/september-2019-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ But this summary is just scratching the surface. We have accepted 199 commits fr
- 🧮 We will start to work on a Data Table component.
⭐️ Notice that the advanced features of the data grid will be paid, behind an enterprise subscription. This is an effort part of [our roadmap](/discover-more/roadmap/) to answer enterprise needs.

- ❓ Do you want something in specific? Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues), the number of 👍 matters to us.
- ❓ Please upvote our [GitHub issues](https://github.com/mui-org/material-ui/issues) if you want something specific. The number of 👍 helps us to prioritize.

<hr />

Expand Down
1 change: 0 additions & 1 deletion docs/scripts/buildApi.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

import { mkdir, readFileSync, writeFileSync } from 'fs';
import { getLineFeed } from './helpers';
import path from 'path';
Expand Down
1 change: 0 additions & 1 deletion docs/scripts/buildIcons.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

const path = require('path');
const gm = require('gm');

Expand Down
1 change: 0 additions & 1 deletion docs/scripts/buildServiceWorker.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

const path = require('path');
const fse = require('fs-extra');

Expand Down
1 change: 0 additions & 1 deletion docs/scripts/formattedTSDemos.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

/**
* Transpiles TypeScript demos to formatted JavaScript.
* Can be used to verify that JS and TS demos are equivalent. No introduced change
Expand Down
1 change: 0 additions & 1 deletion docs/scripts/i18n.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

import path from 'path';
import fse from 'fs-extra';
import { pageToTitle } from 'docs/src/modules/utils/helpers';
Expand Down
1 change: 0 additions & 1 deletion docs/scripts/updateIconSynonyms.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */

import 'isomorphic-fetch';
import fse from 'fs-extra';
import path from 'path';
Expand Down
1 change: 0 additions & 1 deletion docs/src/modules/components/AppTableOfContents.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable react/no-danger */

import React from 'react';
import PropTypes from 'prop-types';
import marked from 'marked';
Expand Down
5 changes: 5 additions & 0 deletions docs/src/modules/components/HomeQuickWord.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ const backers = [
alt: 'blokt',
title: 'Leading Cryptocurrency News',
},
{
href: 'https://www.crosswordsolver.com',
alt: 'crosswordsolver',
title: 'Crossword Puzzle Solver',
},
];

const styles = theme => ({
Expand Down
1 change: 1 addition & 0 deletions docs/src/modules/components/MarkdownElement.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ const externs = [
'https://www.amazon.com/',
'https://materialdesignicons.com/',
'https://www.w3.org/',
'https://devexpress.github.io/',
];

renderer.link = (href, title, text) => {
Expand Down
1 change: 0 additions & 1 deletion docs/src/modules/components/Notifications.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable react/no-danger, react-hooks/exhaustive-deps */

import 'isomorphic-fetch';
import React from 'react';
import { useSelector } from 'react-redux';
Expand Down
5 changes: 2 additions & 3 deletions docs/src/modules/components/backers.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,8 @@ via [Patreon](https://www.patreon.com/oliviertassinari)
via [OpenCollective](https://opencollective.com/material-ui)

<p style="display: flex; justify-content: center; flex-wrap: wrap;">
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;">
<img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group" width=100 loading="lazy">
</a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group" width="100" loading="lazy"></a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.crosswordsolver.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/crosswordsolver/avatar.png" alt="crosswordsolver" title="Crossword Puzzle Solver" width="100" loading="lazy"></a>
</p>

### There are more!
Expand Down
1 change: 0 additions & 1 deletion docs/src/modules/components/prism.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable import/no-mutable-exports, global-require */

import prism from 'prismjs';
import 'prismjs/components/prism-css';
import 'prismjs/components/prism-diff';
Expand Down
1 change: 0 additions & 1 deletion docs/src/modules/redux/initRedux.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-underscore-dangle */

import { createStore, combineReducers, applyMiddleware, compose } from 'redux';
import optionsReducer from 'docs/src/modules/redux/optionsReducer';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import { makeStyles } from '@material-ui/core/styles';
import Paper from '@material-ui/core/Paper';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import { makeStyles, Theme, createStyles } from '@material-ui/core/styles';
import Paper from '@material-ui/core/Paper';
Expand Down
1 change: 0 additions & 1 deletion docs/src/pages/components/breadcrumbs/RouterBreadcrumbs.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-nested-ternary */

import React from 'react';
import PropTypes from 'prop-types';
import { makeStyles } from '@material-ui/core/styles';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-nested-ternary */

import React from 'react';
import { makeStyles, Theme, createStyles } from '@material-ui/core/styles';
import List from '@material-ui/core/List';
Expand Down
1 change: 0 additions & 1 deletion docs/src/pages/components/links/ButtonLink.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import Link from '@material-ui/core/Link';

Expand Down
1 change: 0 additions & 1 deletion docs/src/pages/components/links/ButtonLink.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import Link from '@material-ui/core/Link';

Expand Down
1 change: 0 additions & 1 deletion docs/src/pages/components/links/Links.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import { makeStyles } from '@material-ui/core/styles';
import Link from '@material-ui/core/Link';
Expand Down
1 change: 0 additions & 1 deletion docs/src/pages/components/links/Links.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable jsx-a11y/anchor-is-valid */

import React from 'react';
import { makeStyles, createStyles, Theme } from '@material-ui/core/styles';
import Link from '@material-ui/core/Link';
Expand Down
2 changes: 1 addition & 1 deletion docs/src/pages/components/menus/MenuListComposition.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export default function MenuListComposition() {
>
Toggle Menu Grow
</Button>
<Popper open={open} anchorEl={anchorRef.current} keepMounted transition disablePortal>
<Popper open={open} anchorEl={anchorRef.current} transition disablePortal>
{({ TransitionProps, placement }) => (
<Grow
{...TransitionProps}
Expand Down
2 changes: 1 addition & 1 deletion docs/src/pages/components/menus/MenuListComposition.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default function MenuListComposition() {
>
Toggle Menu Grow
</Button>
<Popper open={open} anchorEl={anchorRef.current} keepMounted transition disablePortal>
<Popper open={open} anchorEl={anchorRef.current} transition disablePortal>
{({ TransitionProps, placement }) => (
<Grow
{...TransitionProps}
Expand Down
2 changes: 1 addition & 1 deletion docs/src/pages/components/popover/SimplePopover.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export default function SimplePopover() {
const classes = useStyles();
const [anchorEl, setAnchorEl] = React.useState<HTMLButtonElement | null>(null);

const handleClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleClick = (event: React.MouseEvent<HTMLButtonElement>) => {
setAnchorEl(event.currentTarget);
};

Expand Down
2 changes: 1 addition & 1 deletion docs/src/pages/components/popper/PositionedPopper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default function PositionedPopper() {
const classes = useStyles();

const handleClick = (newPlacement: PopperPlacementType) => (
event: React.MouseEvent<HTMLButtonElement, MouseEvent>,
event: React.MouseEvent<HTMLButtonElement>,
) => {
setAnchorEl(event.currentTarget);
setOpen(prev => placement !== newPlacement || !prev);
Expand Down
4 changes: 2 additions & 2 deletions docs/src/pages/components/snackbars/snackbars.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ For more advanced use cases you might be able to take advantage of:
![stars](https://img.shields.io/github/stars/iamhosseindhv/notistack.svg?style=social&label=Stars)
![npm downloads](https://img.shields.io/npm/dm/notistack.svg)

We demonstrate how to use [notistack](https://github.com/iamhosseindhv/notistack).
notistack has an **imperative API** that makes it easy to display toasts (so you don't have to deal with open/close state of them).
This example demonstrates how to use [notistack](https://github.com/iamhosseindhv/notistack).
notistack has an **imperative API** that makes it easy to display snackbars, without having to handle their open/close state.
It also enables you to **stack** them on top of one another (although this is discouraged by the Material Design specification).

{{"demo": "pages/components/snackbars/IntegrationNotistack.js", "defaultCodeOpen": false}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,27 +26,27 @@ interface TablePaginationActionsProps {
count: number;
page: number;
rowsPerPage: number;
onChangePage: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>, newPage: number) => void;
onChangePage: (event: React.MouseEvent<HTMLButtonElement>, newPage: number) => void;
}

function TablePaginationActions(props: TablePaginationActionsProps) {
const classes = useStyles1();
const theme = useTheme();
const { count, page, rowsPerPage, onChangePage } = props;

const handleFirstPageButtonClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleFirstPageButtonClick = (event: React.MouseEvent<HTMLButtonElement>) => {
onChangePage(event, 0);
};

const handleBackButtonClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleBackButtonClick = (event: React.MouseEvent<HTMLButtonElement>) => {
onChangePage(event, page - 1);
};

const handleNextButtonClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleNextButtonClick = (event: React.MouseEvent<HTMLButtonElement>) => {
onChangePage(event, page + 1);
};

const handleLastPageButtonClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleLastPageButtonClick = (event: React.MouseEvent<HTMLButtonElement>) => {
onChangePage(event, Math.max(0, Math.ceil(count / rowsPerPage) - 1));
};

Expand Down Expand Up @@ -122,10 +122,7 @@ export default function CustomPaginationActionsTable() {

const emptyRows = rowsPerPage - Math.min(rowsPerPage, rows.length - page * rowsPerPage);

const handleChangePage = (
event: React.MouseEvent<HTMLButtonElement, MouseEvent> | null,
newPage: number,
) => {
const handleChangePage = (event: React.MouseEvent<HTMLButtonElement> | null, newPage: number) => {
setPage(newPage);
};

Expand Down
2 changes: 1 addition & 1 deletion docs/src/pages/components/tree-view/tree-view.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ Tree views can be used to represent a file system navigator displaying folders a

(WAI-ARIA: https://www.w3.org/TR/wai-aria-practices/#TreeView)

The component follows the WAI-ARIA best practices.
The component follows the WAI-ARIA authoring practices.
3 changes: 2 additions & 1 deletion docs/src/pages/discover-more/backers/backers.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ via [Patreon](https://www.patreon.com/oliviertassinari)
via [OpenCollective](https://opencollective.com/material-ui)

<p style="display: flex; justify-content: center; flex-wrap: wrap;">
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group"></a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.call-em-all.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/proxy/images?src=https%3A%2F%2Fopencollective-production.s3-us-west-1.amazonaws.com%2Ff4053300-e0ea-11e7-acf0-0fa7c0509f4e.png&height=100" alt="callemall" title="The easy way to message your group" width="100" loading="lazy"></a>
<a data-ga-event-category="sponsors" data-ga-event-action="logo" data-ga-event-label="callemall" href="https://www.crosswordsolver.com" rel="noopener nofollow" target="_blank" style="margin-right: 16px;"><img src="https://images.opencollective.com/crosswordsolver/avatar.png" alt="crosswordsolver" title="Crossword Puzzle Solver" width="100" loading="lazy"></a>
</p>

## Silver Sponsors
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-script-url */

import React from 'react';
import Link from '@material-ui/core/Link';
import { makeStyles } from '@material-ui/core/styles';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-script-url */

import React from 'react';
import Link from '@material-ui/core/Link';
import { makeStyles } from '@material-ui/core/styles';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const StyledMenu = styled(({ className, ...props }) => (
export default function StyledComponentsPortal() {
const [anchorEl, setAnchorEl] = React.useState<EventTarget | null>(null);

const handleClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
const handleClick = (event: React.MouseEvent<HTMLButtonElement>) => {
setAnchorEl(event.currentTarget);
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,20 +175,21 @@ If you are using Create React App, you will need to use a couple of projects tha

Note: You may run into errors like these:

```
Module not found: Can't resolve '@material-ui/core/makeStyles' in '/your/project'
Module not found: Can't resolve '@material-ui/core/createStyles' in '/your/project'
```
> Module not found: Can't resolve '@material-ui/core/makeStyles' in '/your/project'

This is because `@material-ui/styles` is re-exported through `core`, but the full import is not allowed.

You have an import like this in your code:

`import {makeStyles, createStyles} from '@material-ui/core';`
```js
import { makeStyles, createStyles } from '@material-ui/core';
```

The fix is simple, define the import separately:

`import {makeStyles, createStyles} from '@material-ui/core/styles';`
```js
import { makeStyles, createStyles } from '@material-ui/core/styles';
```

Enjoy significantly faster start times.

Expand Down
2 changes: 1 addition & 1 deletion examples/create-react-app-with-typescript/src/index.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import ReactDOM from 'react-dom';
import CssBaseline from '@material-ui/core/CssBaseline';
import { ThemeProvider } from '@material-ui/styles';
import { ThemeProvider } from '@material-ui/core/styles';
import App from './App';
import theme from './theme';

Expand Down
2 changes: 1 addition & 1 deletion examples/create-react-app/src/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import ReactDOM from 'react-dom';
import CssBaseline from '@material-ui/core/CssBaseline';
import { ThemeProvider } from '@material-ui/styles';
import { ThemeProvider } from '@material-ui/core/styles';
import App from './App';
import theme from './theme';

Expand Down
Loading