@aboutbits/react-material-icons 中文文档教程
React Material Icons
这个包包括所有 Material Icons 作为可重用的 React 组件。
Table of content
Usage
首先,您必须安装包:
npm install @aboutbits/react-material-icons
其次,您可以像这样在 React 应用程序中使用图标:
import React from 'react'
import IconCached from '@aboutbits/react-material-icons/dist/IconCached'
const MyCommponent = () => {
return (
<IconCached />
);
}
高度和宽度等 SVG 相关参数可以作为道具传递。
Generate Components
要生成组件,只需运行以下命令:
npm run generate
Build & Publish
要发布包,提交所有更改并将它们推送到 master。 然后在本地运行以下命令之一:
npm version patch
npm version minor
npm version major
Information
About Bits 是一家位于意大利南蒂罗尔的公司。 您可以在我们的网站上找到更多关于我们的信息。
Support
如需支持,请联系 info@aboutbits.it。
Credits
License
麻省理工学院许可证(麻省理工学院)。 请参阅许可文件了解更多信息。
React Material Icons
This package includes all Material Icons as reusable React components.
Table of content
Usage
First, you have to install the package:
npm install @aboutbits/react-material-icons
Second, you can use the icons in you React application like this:
import React from 'react'
import IconCached from '@aboutbits/react-material-icons/dist/IconCached'
const MyCommponent = () => {
return (
<IconCached />
);
}
SVG related parameters like height and width can be passed as props.
Generate Components
To generate the components, simply run the following command:
npm run generate
Build & Publish
To publish the package commit all changes and push them to master. Then run one of the following commands locally:
npm version patch
npm version minor
npm version major
Information
About Bits is a company based in South Tyrol, Italy. You can find more information about us on our website.
Support
For support, please contact info@aboutbits.it.
Credits
License
The MIT License (MIT). Please see the license file for more information.