首页 > 解决方案 > CoreUI icons from npm not showing in ReactJS project

问题描述

I've installed @coreui/icons with npm install --save successfully, but now that I make a div or span or anything with class as suggested here https://www.npmjs.com/package/@coreui/icons, nothing shows up.

I'm developing a project with React, if that matters.

So in my component's render function I have:

render() {
    return(<div>
        <i className="cui-energy"></i>
        <i class="cui-energy"></i>
    </div>)
}

But literally nothing is showing. Do I need to import a css file or anything for it to work?

标签: javascriptreactjscore-ui

解决方案


推荐阅读