Enable gutenberg block on woocommerce product page June 19, 2022

To enable Gutenberg block editor on the WooCommerce product page you just need to insert a small code snippet into your functions.php Please flow the below process to do it.

What is Gutenberg?

Gutenberg is a brand new editor for the WordPress platform. It will radically change the way you create posts, pages, products, and just about everything else on your site. Gutenberg arrived as part of WordPress 5.0, which was released on November 27, 2018. For that reason, it’s important to get up to speed now.

Enable Gutenberg Block Editor on WooCommerce Product Page

  1. Login to your WordPress Website.
  2. Click on Appearance
  3. Navigate to Theme file Editor
  4. Then open the functions.php file.
  5. Then paste the below code into the file and update the file.

function codepopular_activate_gutenberg_products($can_edit, $post_type){
	if($post_type == 'product'){
		$can_edit = true;
	}
	
	return $can_edit;
}
add_filter('use_block_editor_for_post_type', 'codepopular_activate_gutenberg_products', 10, 2);



What Video to Enable Gutenberg

How to Disable Gutenberg Block Editor?

If you don’t want to use Gutenberg block editor then you can remove it easily. We have a block about How to remove the Gutenberg Block editor. If you need any kind of help Please feel free to contact us we will try to reply to you as soon as possible.

Like this article? Spread the word

Share Share Share Share

Support Me to Buy a Coffee

If you like my blog or Free WordPress Theme and Plugin then Please make me happy to buy a Coffee to bing more inspired to contribute to it.

1 thought on “Enable Gutenberg Block Editor on WooCommerce Product Page

Leave a Reply

Your email address will not be published. Required fields are marked *

Support Me to Buy a Coffee

If you like my blog or Free WordPress Theme and Plugin then Please make me happy to buy a Coffee to bing more inspired to contribute on it.