Snippets Collections
//How to Disable Gutenberg & Return to the Classic WordPress Editor Without any Plugins

add_filter( 'use_block_editor_for_post', '__return_false' );
remove_theme_support(  'block-templates' );
<?php
/**
 * Gutenberg Examples Stylesheets
 */
 
function gutenberg_examples_02_register_block() {
    wp_register_script(
        'gutenberg-examples-02',
        plugins_url( 'block.js', __FILE__ ),
        array( 'wp-blocks', 'wp-element' ),
        filemtime( plugin_dir_path( __FILE__ ) . 'block.js' )
    );
 
    wp_register_style(
        'gutenberg-examples-02-editor',
        plugins_url( 'editor.css', __FILE__ ),
        array( 'wp-edit-blocks' ),
        filemtime( plugin_dir_path( __FILE__ ) . 'editor.css' )
    );
 
    wp_register_style(
        'gutenberg-examples-02',
        plugins_url( 'style.css', __FILE__ ),
        array( ),
        filemtime( plugin_dir_path( __FILE__ ) . 'style.css' )
    );
 
    // Allow inlining small stylesheets on the frontend if possible.
    wp_style_add_data( 'gutenberg-examples-02', 'path', dirname( __FILE__ ) . '/style.css' );
 
    register_block_type( 'gutenberg-examples/example-02-stylesheets', array(
        'api_version' => 2,
        'style' => 'gutenberg-examples-02',
        'editor_style' => 'gutenberg-examples-02-editor',
        'editor_script' => 'gutenberg-examples-02',
    ) );
}
add_action( 'init', 'gutenberg_examples_02_register_block' );
$ npx @wordpress/create-block [options] [slug]
.oxygen-body{
  /* Full width styling for Oxygen Gutenberg blocks and Gutenberg images*/
  width:100vw;
  overflow-x:hidden;
}

.alignfull {
    margin-left  : calc( -100vw / 2 + 100% / 2 );
    margin-right : calc( -100vw / 2 + 100% / 2 );
    max-width    : 100vw;
}
star

Thu Nov 18 2021 03:18:48 GMT+0000 (Coordinated Universal Time)

#wordpress #php #gutenberg
star

Thu Nov 18 2021 03:18:21 GMT+0000 (Coordinated Universal Time)

#php #gutenberg #wordpress
star

Mon Oct 25 2021 05:31:55 GMT+0000 (Coordinated Universal Time) https://developer.wordpress.org/block-editor/how-to-guides/block-tutorial/applying-styles-with-stylesheets/

#wordpress #gutenberg #styles
star

Mon Oct 25 2021 05:16:11 GMT+0000 (Coordinated Universal Time) https://www.npmjs.com/package/@wordpress/create-block

#wordpress #gutenberg #git #npm
star

Mon Oct 25 2021 04:49:03 GMT+0000 (Coordinated Universal Time) https://www.wordstamped.com/1022/full-width-oxygen-block/

#wordpress #oxygen #css #gutenberg

Save snippets that work with our extensions

Available in the Chrome Web Store Get Firefox Add-on Get VS Code extension