Clear WP Fastest Cache when a Beaver Builder layout is published

Note: This fix is no longer required because Beaver Builder now automatically clears the caches of many services and plugins, including WP Fastest Cache plugin. See the Related Article below for more information on how to enable or disable the Beaver Builder Cache Clearing Tool.

You can add PHP code that will force the WP Fastest Cache plugin to clear its cache when a Beaver Builder layout is published.

Add the following code to your child theme's functions.php file.

add_action ( 
    'after_setup_theme', function() { 
        add_action( 'fl_builder_after_save_layout', 
        array( $GLOBALS['wp_fastest_cache'], 'deleteCache' ) ); 
    } 
);

Why do you need a child theme? See this section in the article about theme installation.