You may use the following code (either in your active theme’s functions.php
file or in a custom plugin):
// This line is preferably be added to your theme's functions.php file
// with other add_theme_support() function calls.
add_theme_support( 'disable-layout-styles' );
// These two lines will probably not be necessary eventually
remove_filter( 'render_block', 'wp_render_layout_support_flag', 10, 2 );
remove_filter( 'render_block', 'gutenberg_render_layout_support_flag', 10, 2 );
The above code should remove the classes like is-layout-flex
, is-layout-flow
etc.
Caution: These are added for good reasons. So, unless you absolutely have to remove these, I’d suggest you to go through the following links before making the final decision:
Related Posts:
- get_template_part vs action hooks in themes
- How to remove the Theme Customization Button from the dashboard and themes options page?
- Edit srcset and sizes attributes in Gutenberg image, cover and gallery – blocks
- Getting instance variable in scope of ‘wp_enqueue_scripts’
- Display a different theme for not logged-in users
- How do I Make a Theme “plugin-ready”?
- What’s the difference between hooks, filters and actions? [duplicate]
- How to use filter hook ‘post_updated_messages’ in coherence with action hook ‘save_post’
- Get password when user registers and save it sha1 into database
- Passing variable in hooks and filter
- Highlight “Show all” item in wp_list_categories
- Menu item added in wp_nav_menu_items filter is never highlighted
- Pass variable to hook. Its possible?
- What is the “correct” way to add hooks or similar PHP behavior to a blocktheme?
- WordPress taxonomy and archive custom class
- How to wrap all titles generated by Gutenberg “Heading” block with tag
- How to change footer credit text in Twenty Twenty One theme with a hook?
- Modify available templates (in dropdown)
- Add content after get_header
- WordPress wp_get_current_user returning blank values until refresh
- what is do_action(); in wordpress? [duplicate]
- Suppress the_content filter in a nested loop
- Add text when displying attribute with a hook on single product page
- How to know what functions are hooked to an action/filter?
- Is there any action filter/hook for validating a custom field before publishing the post?
- Earliest hook to reliably get $post/$posts
- What does (10, 2) mean when used with add_filter
- How to modify an image block in Gutenberg WordPress 5?
- Valid characters for actions, hooks and filters
- Proper, exhaustive documentation for wp.editor etc
- How to check if a hook is hooked or not?
- What can I hook into after_setup_theme?
- Run shortcode before filters
- Hook into admin post list page
- Theme elements not translating
- About Hooks and Filters
- Should I use add_action(‘publish_post or add_filter(‘publish_post?
- Is it possible to create an action hook using do_action() within add_action()?
- Use external link in the add sub menu
- How to get list of all hooks of current theme / plugin?
- wp_enqueue_scripts not called on search page?
- WordPress Genesis Child Theme Filter divs
- Gutenberg Reusable Block as part of WordPress Theme page
- What is the action hook for an order that fails on frontend checkout in WooCommerce?
- Change file name from wp_generate_attachment_metadata
- Use debugging for add action events
- Creating multiple hooks for theme
- after_setup_theme, Global Variable and Theme Customizer
- Accepted arguments value in hook functions
- how to determine how many and what kind of arguments are passed to hooks
- Can the wp_filter object hold multiple values with the same key
- Gutenberg – editor-font-sizes in functions not working
- Which action hook to use for function?
- How to add theme support?
- apply_filters/do_action tag characters limit
- Should I use function_exists() and/or add_action() in theme development?
- Which file handles the block latest posts, I want to examine excerpt handling
- Modify a function without editing template
- Single-level menu option? Another way?
- How to change database values on theme update
- Not able to select width of blocks inside of cover block
- How to remove action with slashes and arrows?
- gutenberg add classes to list items
- Changing WordPress core without hacking core
- Comment search plugin
- Filter Posts from the Main Query
- Issue understanding and using WordPress filters and actions
- Dynamic menu links after header title
- Gutenberg Block – Post Featured Image Filter Hook
- How to rotate every letter in a title
- Overide enqueue in non plugable function via child theme
- CSS class on last post in loop ( custom query )
- Call to undefined function is_home() or any conditional tags
- HTML block gutenberg templates
- Use a filter on menu items that have children
- Insert Content Before div#main from the functions.php File
- How can I edit comment meta value before it is saved?
- Filter didn’t work on content class (hybrid_post_attributes)
- What filter or action hook to use in order to load some code before the template begins printing in BuddyPress? [closed]
- Pagination don’t work with active filters
- Display custom product option in admin order details
- style_loader_tag not changing stylesheet to preload
- restrain filter on get_the_excerpt to queried item in stead of current post
- How to diagnose wp-env environment problem
- How can I include custom Gutenberg Blocks in a theme?
- Block validation failed for `core/pullquote` after adding theme support for editor-color-palette
- Alt header logo and link for specific pages
- Alter theme pages on language switch
- Hook inside a hook
- Hook in parent theme Menu function
- How to add custom nav_menu_css_class to certain menu only?
- How to add custom checkout field in user details mail template
- Correct way to make a custom block theme responsive
- Is there a way to prevent wp_head from outputting self-closing tags?
- Multiple content areas with Gutenberg – Transparent areas mid content
- Can you call a filter hook by “add_action”?
- Can’t select my block by clicking on it on apiVersion – but using blockProps
- How to set the margin on an innerBlock in a block variation?
- Align images to the left of the content
- Ninja Forms: Front-End Forms, Post ID?