Sara
Sara

Reputation: 21

Typography Material UI not found

The Material UI library doesn't respond in case when typography is separately installed in the project libraries.
The project isn't compiling and giving this error

./src/App.js

Module not found: Can't resolve 'material-ui/Typography' in 'C:\Users\Sara Durrani\react\screenstask\src'

Upvotes: 1

Views: 3749

Answers (2)

JustAG33K
JustAG33K

Reputation: 1556

You will have import Typography like this:

import Typography from '@mui/material/Typography';

Upvotes: 0

tonysepia
tonysepia

Reputation: 3510

Just had the same problem. Apparently now you have to import it from core:

import Typography from '@material-ui/core/Typography'

Upvotes: 2

Related Questions