Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Adds revision support to the wp_block post type. Can be deleted after this issue https://github.com/WordPress/gutenberg/issues/19149 is closed & merged into WordPress Core
<?php
/*
Plugin Name: Reusable Block Revisions
Plugin URI: http://travel-dealz.de/
Description: Adds revision support to the wp_block post type. Can be deleted after this issue https://github.com/WordPress/gutenberg/issues/19149 is closed & merged into WordPress Core
Version: 1.0.0
Author: Johannes Kinast
Author URI: https://go-around.de
Min WP Version: 5.0
Max WP Version: 5.7
*/
namespace Reusable_Block_Revisions;
function reusable_block_revisions() {
add_post_type_support( 'wp_block', 'revisions' );
}
add_action( 'init', __NAMESPACE__ . '\reusable_block_revisions' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment