Dandelion Pro - React Admin Dashboard Template 开发过程中遇见的问题总结

2 篇文章 0 订阅
2 篇文章 0 订阅

1、问题特征:The `fab` variant will be removed in the next major release. The `<Fab>` component is equivalent and should be used instead.

解决方案:

说明:一般这个文件在于头文件中,例如:app/components/Header/Header.js

将 import Button from '@material-ui/core/Button';
替换成 import Fab from '@material-ui/core/Fab';

将
<Button variant="fab" mini className={classes.menuButton} aria-label="Menu" onClick={toggleDrawerOpen} >
   <MenuIcon />
</Button>
替换成
<Fab color="primary" size="small" className={classes.menuButton} aria-label="Menu" onClick={toggleDrawerOpen}>
   <MenuIcon />
</Fab>

 

搜索关键词:

Warning: Failed prop type: The `fab` variant will be removed in the next major release. The `<Fab>` component is equivalent and should be used instead.
    in Button (created by WithStyles(Button))
    in WithStyles(Button) (created by Header)
    in div (created by Toolbar)
    in Toolbar (created by WithStyles(Toolbar))
    in WithStyles(Toolbar) (created by Header)
    in header (created by Paper)
    in Paper (created by WithStyles(Paper))
    in WithStyles(Paper) (created by AppBar)
    in AppBar (created by WithStyles(AppBar))
    in WithStyles(AppBar) (created by Header)
    in Header (created by WithStyles(Header))
    in WithStyles(Header) (created by LeftSidebarLayout)
    in LeftSidebarLayout (created by WithStyles(LeftSidebarLayout))
    in WithStyles(LeftSidebarLayout) (created by Dashboard)
    in div (created by Dashboard)
    in Dashboard (created by Connect(Dashboard))
    in Connect(Dashboard) (created by WithStyles(Connect(Dashboard)))
    in WithStyles(Connect(Dashboard)) (created by Application)
    in Application (created by Route)
    in Route (created by Context.Consumer)
    in Switch (created by Context.Consumer)
    in div (created by ThemeWrapper)
    in MuiThemeProviderOld (created by ThemeWrapper)
    in ThemeWrapper (created by Connect(ThemeWrapper))
    in Connect(ThemeWrapper) (created by WithStyles(Connect(ThemeWrapper)))
    in WithStyles(Connect(ThemeWrapper)) (created by WithTheme(WithStyles(Connect(ThemeWrapper))))
    in WithTheme(WithStyles(Connect(ThemeWrapper))) (created by App)
    in App
    in Router (created by ConnectedRouter)
    in ConnectedRouter (created by Connect(ConnectedRouter))
    in Connect(ConnectedRouter)
    in IntlProvider (created by LanguageProvider)
    in LanguageProvider (created by Connect(LanguageProvider))
    in Connect(LanguageProvider)
    in Provider

2、问题特征:npm i *** 或者 npm install *** 之后:The DLL manifest is missing. Please run `npm run build:dll`. 

解决方案:

加上 -g 参数,例如:npm i -g @fortawesome/react-fontawesome

3、问题特征:error Newline required at end of file but not found eol-last

搜索关键词:

ERROR in ./app/containers/pageListAsync.js

Module Error (from ./node_modules/eslint-loader/index.js):

C:\Users\leroi\Desktop\themeforest-update\dandelion_pro_v130\starter-project\app\containers\pageListAsync.js

59:4 error Newline required at end of file but not found eol-last

✖ 1 problem (1 error, 0 warnings)

1 error and 0 warnings potentially fixable with the `--fix` option.

解决方案:

在提示的文件最后加一个空行,可以说这问题真TM的坑!!!!!!!!!!!!

4、问题特征:error  Expected linebreaks to be 'LF' but found 'CRLF' linebreak-style

搜索关键词:

error  Expected linebreaks to be 'LF' but found 'CRLF'             linebreak-style

解决方案:

在项目目录下找到.eslintrc.js文件,在rules下添加'linebreak-style': [0, 'error', 'windows']。记得重启项目

 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值