• Resolved Nick Diego

    (@ndiego)


    Hi Marc,

    First off, great plugin. However, I did run into an error in the Site Editor where I have the the block in a sidebar template part that is separate from the main content area. On the frontend, everything works, except for the render_block filter. The ids are not getting added to the headings.

    I believe the filter is being called too early, before all the necessary templates and template parts have been retrieved.

    Anyway, if you filter render_block after plugins have loaded, everything seems to work as expected. My quick solution was the following:

    add_action( 'plugins_loaded', __NAMESPACE__ . '\\filter_render_block_callback' );
    
    function filter_render_block_callback() {
        //add only if block is used in this post.
        add_filter( 'render_block', __NAMESPACE__ . '\\filter_block', 10, 2 );
    };

    You may want to test this a bit, but I can confirm it is working for me in the the TT1 Blocks theme.

    Hope that helps.

    – Nick

Viewing 11 replies - 1 through 11 (of 11 total)
Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Plugin not working with Full Site Editing (I have a fix)’ is closed to new replies.