acf/blocks/default_block_version
Description
Used to opt all of your ACF Blocks into a specific version.
Changelog
- Added in version 6.6
Example
functions.php
function my_custom_function_to_bump_the_block_version( $version, $block ) {
return 3; // Use v3
}
add_filter( 'acf/blocks/default_block_version', 'my_custom_function_to_bump_the_block_version', 10, 2 );
Notes
If you have defined the ‘blockVersion’ specifically in your block.json file, the filter will not override that.
这篇文档对你有帮助吗?
谢谢你的反馈!