index_20190418115649.js 585 Bytes
Newer Older
baiguangyao committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
import React, { Component } from 'react'
import { NavLink } from 'react-router-dom';
import './index.scss'

export default class NavLinks extends Component {
    render() {
        const { pathUrl, active, icoName, linkName, ...rest } = this.props;
        return (
            <NavLink
                {...rest}
                to={pathUrl}
                activeClassName={active}
                className={"root-item "}
            >
                <i className={"icoName ico"} />
                <span className={"text"}>{linkName}</span>
            </NavLink>
        )
    }
}