Article From:

Configure routing here in main.js

    <Router history={hashHistory} >
        <Route path="/" component={Sider}>
            <IndexRoute path="myCreditCard" component={myCreditCard} />
            <Route path="myOverview" component={myOverview} />
), document.getElementById('app'));

overview.jsIt’s like this.

import React from 'react'
import {Steps, Icon} from 'antd'
const Step = Steps.Step

export default class myOverview extends React.Component {
    constructor(props) {
        this.state = {
            tDate: [],
            selectedRowKeys: []
    componentDidMount() {
    render() {
        return (
                <Step status="finish" title="The loan "icon={< Icon type=" heart "/>} />";< Step status= "finish" title= "investment" icoN={< Icon type= "solution" />} />< Step status= "process" title= "repayment" icon={< Icon type= "credit-card" />} />< Step status= "wait" title= "complete" icon={<Icon type= "smile-o" />} />< /Steps>)}}

stepIt can be displayed, but < Icon> but not generated. There is no mistake.
I wanted to ask on GitHub. But they say that the problem of using can not be asked on that, it can only mention bug or pullrequest.
Good hands to help see what reason.

Answer 0:

Try to upgrade the version of antd

Answer 1:

The information is not detailed enough.
1、See if there is a request failure in the console network.
2、Other components that use Icon can not be displayed properly? If not, it is very likely that there is a problem with the configuration of webpack.

Leave a Reply

Your email address will not be published. Required fields are marked *