简体   繁体   中英

VS Code Intelli-sense does not show suggestions for react-icons even after installing react-icons properly using npm

I installed react-icons library using the command,

npm install react-icons --save

It installed well.

Then I tried writing import statement for importing IoIosStarOutline icon in VS Code editor, then its intelli-sense does not suggest the name of the icon. I even tried importing FaBeer icon in VS Code, it still does not suggest it. I installed latest ES7 React extensions but nothing seems working.

It only shows suggestion for IconBase from react-icons.

What must be the problem? I am stuck, can anyone help? I am using UBUNTU os.

After several tryouts I found that developer has to first write the from "react-icons/io" part of the import statement and then the import suggests the names of icons.

Problem is solved. But I would close on a note that VS Code should pay attention to this thing, as react-icons is widely used library and some names are so huge that intellisense is the only option.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM