To get details of any given registered Gutenberg block, you must at least know its name. For example, the registered name of the Paragraph block is core/paragraph
.
If you’re unsure about the registered name of a block, this post will help you to get details of all the blocks.
Once you have the name, use the following snippet:
wp.blocks.getBlockType( 'core/paragraph' );
Code language: JavaScript (javascript)
That’s it!
Leave a Reply