Skip to content

Commit 224e21c

Browse files
committed
Disable JSX Attr by default
1 parent ade616d commit 224e21c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

includes/helpers.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@ function block_attrs( array $block, string $custom_class = '', array $attrs = []
5757
$attrs['style'] = $block_styles;
5858
}
5959

60-
if ( ! array_key_exists( 'data-supports-jsx', $attrs ) && ! empty( $block['supports']['jsx'] ) ) {
60+
$jsx_attr = apply_filters( 'vgtbt_block_jsx_attr', false );
61+
if ( $jsx_attr && ! array_key_exists( 'data-supports-jsx', $attrs ) && ! empty( $block['supports']['jsx'] ) ) {
6162
$attrs['data-supports-jsx'] = 'true';
6263
}
6364

0 commit comments

Comments
 (0)