简体   繁体   English

尝试导入错误:“GlobalStyles”未从“@material-ui/system”导出(导入为“SystemGlobalStyles”)

[英]Attempted import error: 'GlobalStyles' is not exported from '@material-ui/system' (imported as 'SystemGlobalStyles')

./node_modules/@material-ui/core/GlobalStyles/GlobalStyles.js Attempted import error: 'GlobalStyles' is not exported from '@material-ui/system' (imported as 'SystemGlobalStyles'). ./node_modules/@material-ui/core/GlobalStyles/GlobalStyles.js 尝试导入错误:“GlobalStyles”未从“@material-ui/system”导出(导入为“SystemGlobalStyles”)。

I'm facing this problem and I can't understand in which file it's occuring.我正面临这个问题,我无法理解它发生在哪个文件中。

I found the solution to this question.我找到了这个问题的解决方案。

  1. Delete @material-ui folder from node_modules .node_modules中删除@material-ui文件夹。

  2. Run npm i @mui/material in the terminal.在终端中运行npm i @mui/material

  3. Check for the correct spellings in the import statement.检查导入语句中的正确拼写。 It should be from "@material-ui/core" ;它应该from "@material-ui/core"

This worked for me!这对我有用! :) :)

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 尝试导入错误:“makeStyles”未从“@material-ui/core/styles”导出 - Attempted import error: 'makeStyles' is not exported from '@material-ui/core/styles' ./src/components/styles.js 尝试导入错误:'@material-ui/core/styles' 不包含默认导出(作为 'makeStyles' 导入) - ./src/components/styles.js Attempted import error: '@material-ui/core/styles' does not contain a default export (imported as 'makeStyles') 尝试导入错误:“app”未从“firebase/app”导出(导入为“firebase”) - Attempted import error: 'app' is not exported from 'firebase/app' (imported as 'firebase') 尝试导入错误:“create”未从“fontkit”导出(导入为“fontkit”) - Attempted import error: 'create' is not exported from 'fontkit' (imported as 'fontkit') 尝试导入错误:'未从 - Attempted import error:' is not exported from 尝试导入错误:“BrowseRouter”未从“react-router-dom”导出(导入为“Router”) - Attempted import error: 'BrowseRouter' is not exported from 'react-router-dom' (imported as 'Router') 升级到 Firebase JS 8.0.0:尝试导入错误:“app”未从“firebase/app”导出(导入为“firebase”) - Upgrade to Firebase JS 8.0.0: Attempted import error: 'app' is not exported from 'firebase/app' (imported as 'firebase') 尝试导入错误:“SupportedPackages”未从“@tensorflow-models/facemesh”导出(导入为“facemesh”) - Attempted import error: 'SupportedPackages' is not exported from '@tensorflow-models/facemesh' (imported as 'facemesh') 尝试导入错误:“Typography”未从“antd”导出 - Attempted import error: 'Typography' is not exported from 'antd' 尝试导入错误:“必需”未从“是的”导出 - Attempted import error : 'required' is not exported from 'yup'
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM