Reputation: 11
I'm working on a school project that was created three years ago. The icons render just fine on the website, but they don't display on my computer.
The original code looks like this:
<CIcon icon="sidebar_icon" customClassName="nav-icon" />
and it responded with undefined.
After running some tests, I found that the following works on my machine:
<CIcon icon={React.icons.sidebar_icon} customClassName="nav-icon" />
This successfully renders the SVG content as defined in other files.
Since this project is part of a public repo, and that the tags are used extensively throughout the codebase, I'm hesitant to modify every icon for fear that it breaks compatibility for other developers working on the project.
Is there a way to fix this without changing the code everywhere? For example, would downgrading CoreUI or adjusting some configuration help? Any advice would be greatly appreciated!
Upvotes: 1
Views: 18