How to use the @ant-design/icons-react/esm.add function in @ant-design/icons-react

To help you get started, we’ve selected a few @ant-design/icons-react examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ant-design / ant-design-icons / packages / icons-react / examples / simple / pages / index.jsx View on Github external
import * as React from 'react';
import styles from './index.less';
import { Alibaba, Dashboard, DashboardFill, Twitter } from '@ant-design/icons/esm';
import AntdIcon from '@ant-design/icons-react/esm';

AntdIcon.add(Alibaba, Dashboard, DashboardFill);

export default class IndexPage extends React.Component {
  render() {
    return (
      <div>
        
        
        
        <div>
          <span style="{{">
            64px ABC
          </span>
          
          <p>SVG element could not align to text.<br>You should set <code>vertical-align: -.125em</code></p>
        </div>
      </div>

@ant-design/icons-react

<h1 align="center"> Ant Design Icons for React </h1>

MIT
Latest version published 6 years ago

Package Health Score

66 / 100
Full package analysis