Accept array of block names in registerBlockStyle #50256
Labels
Developer Experience
Ideas about improving block and theme developer experience
[Feature] Block API
API that allows to express the block paradigm.
[Feature] Block Style Variations
Issues or PRs that are related to the style variations for blocks
[Type] Enhancement
A suggestion for improvement.
What problem does this address?
When registering block styles using
wp.blocks.registerBlockStyle
, I often want to add the same block style to multiple similar blocks that might need to have the same appearance, and I end up doing something like this:This is obviously easy enough, but it makes switching from registering a single block style to multiple block styles slightly awkward.
What is your proposed solution?
Accept either a single block name or an array of block names when calling
wp.blocks.registerBlockStyle
.The text was updated successfully, but these errors were encountered: