acf_has_block_type()
Returns true if a block type exists for the given name.
No Hooks.
Returns
true|false.
Usage
acf_has_block_type( $name );
- $name(string) (required)
- The block type name.
Changelog
| Since 5.7.12 | Introduced. |
acf_has_block_type() acf has block type code ACF 6.8.8
function acf_has_block_type( $name ) {
return acf_get_store( 'block-types' )->has( $name );
}