-
I'm trying to use the
To display the import { Icon, postStatus } from '@wordpress/icons';
<Icon icon={ postStatus } />; The issue - As far as I can tell, this icon doesn't exist within the icons package. Either that, or I'm utterly blind and need my eyes tested? Would one of you lovely people be able to confirm what I'm not seeing? 👌 I appreciate any help. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
So after a little digging and being maybe a little bit oblivious 😅. The correct way to use import { Dashicon } from "@wordpress/components";
<Dashicon icon="post-status" /> Note: This info can be found in the Anyways, here's a direct link to the instructions on how to use |
Beta Was this translation helpful? Give feedback.
So after a little digging and being maybe a little bit oblivious 😅. The correct way to use
dashicons
within WordPress is as follows;Note: This info can be found in the
Developer Resources: Dashicons
docs, but annoyingly it is buried at the bottom of the page. There are no links to this info at the top of the page, so I didn't even know it existed. 🙃Anyways, here's a direct link to the instructions on how to use
Dashicons
from@wordpress/components
You'll find the specifics under Block Usage.