做流行的开源 React UI 组件库
- material-ui 国外流行(安卓手机的界面效果)
- ant-design 国内流行 (蚂蚁金服 设计,一套 PC、一套移动端的____下拉菜单、分页......)
create-react-app myApp
yarn add antd
在 index.js 中 import "antd/dist/antd.min.js" 会打包全部文件
需要按需打包
// 最新版本有问题
yarn add [email protected] babel-plugin-import --save -D
yarn remove react-scripts
yarn add [email protected] --save
// 注意屏蔽 import "antd/dist/antd.min.js"
// 注意去掉 package.json 原来的 react-scripts // 区别在于引入了配置
基于 react+antd 后台管理系统 (现实生活中,react 做后台界面的更常见)
5
5
5
5
5
5
5
5
5
5
5
5
5