• Resolved wiebke.wetzel

    (@wiebkewetzel)


    Hello,
    the woocommerce plugin still uses the classic editor for product pages and I appreciate that you don’ want to break established shops by disabling the classic editor.
    As Gutenberg was launched end of 2018 it would be great to finally have a choice between Gutenberg and classic editor for woocommerce product pages. With the classic editor one is very limited in page design compared to Gutenberg editor.
    Thanks,
    Wiebke

Viewing 7 replies - 1 through 7 (of 7 total)
  • They have disabled it for some reason – I suspect for compatibility issues maybe?

    Ypu can enable it though. Use this code – I use the Code Snippets plugin to add it: https://wplook.com/how-to-enable-gutenberg-for-woocommerce-products/

    Hi, wiebke.wetzel, I’m another WooCommerce user, and I found a tutorial that will enable you to use the Gutenberg editor within the product view (if you feel comfortable enough adding additional PHP code):

    https://dev.to/kalimahapps/enable-gutenberg-editor-in-woocommerce-466m

    Just keep in mind that the product_data_visibility function will have to be updated if the function defined within the WooCommerce source code is updated to maintain compatibility.

    Thread Starter wiebke.wetzel

    (@wiebkewetzel)

    Thanks to both of you for your fast answers!
    I will test that. Else I found out that I can write a page with Gutenberg blocks and then copy & paste the content on the product page (in text editor mode). A bit cumbersome but it works without code.

    • This reply was modified 3 years, 3 months ago by wiebke.wetzel.
    Plugin Support Thu P. a11n

    (@thup90)

    Hi all,

    I understand you want to have the option for Gutenberg in product editor. We hear you! There has been internal discussion on how to approach this and we haven’t had a set plan at this time in introducing Gutenberg to the product editor.

    While you might have found custom code that works for now, I’d recommend keeping track of our progress via this page: https://github.com/woocommerce/woocommerce/issues/28419

    Feel free to get back to us in case you have any additional questions!

    Mirko P.

    (@rainfallnixfig)

    Hi there,

    We’ve not seen any activity on this thread for a while, so I’m marking this thread as resolved.

    If you have any further questions, I recommend creating a new thread.

    Thanks.

    Copy and Paste Below Codes in theme’s functions.php
    To Enable Gutenberg Editor in WooCommerce Post Editor

    
    // Enable Gutenberg in WooCommerce
    function activate_gutenberg_product( $can_edit, $post_type ) {
    
        if ( $post_type == 'product' ) {
            $can_edit = true;
        }
        return $can_edit;
    }
    add_filter( 'use_block_editor_for_post_type', 'activate_gutenberg_product', 10, 2 );
    

    That’s all

    one3rdnerd

    (@one3rdnerd)

    @mrskt00

    I am using this snippet and it was working well until I tried to turn reviews on or off on the edit product screen.

    When you try that and then check the front end has it changed? Then refresh the edit product screen and go back down to the Product Data > Advanced tab and see if your change actually saved?

    Thanks

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Gutenberg editor for product pages’ is closed to new replies.