Skip to content

Instantly share code, notes, and snippets.

@wpexplorer
Created February 16, 2022 06:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wpexplorer/2b203f0336ba5d17837c35f1a087c8f6 to your computer and use it in GitHub Desktop.
Save wpexplorer/2b203f0336ba5d17837c35f1a087c8f6 to your computer and use it in GitHub Desktop.
Remove WPBakery elements from the builder.
add_action( 'vc_after_init', function() {
$elements = array(
// Remove core wpbakery elements
'vc_single_image',
// Remove total elements
'vcex_heading',
);
foreach ( $elements as $element ) {
if ( function_exists( 'vc_remove_element' ) ) {
vc_remove_element( $element );
}
}
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment