apply_filters( 'block_editor_settings_all', array $editor_settings, WP_Block_Editor_Context $block_editor_context )

Filters the settings to pass to the block editor for all editor type.

Parameters Parameters


(array) Default editor settings.


(WP_Block_Editor_Context) The current block editor context.

Top ↑

Source Source

File: wp-includes/block-editor.php

View on Trac

Top ↑

Changelog Changelog

Version Description
5.8.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

  1. Skip to note 1 content
    Contributed by thejaydip

    Basic example

    function wp_docs_block_editor_settings( $editor_settings, $editor_context ) {
        if ( ! empty( $editor_context->post ) ) {
            $editor_settings['maxUploadFileSize'] = 12345;
        return $editor_settings;
    add_filter( 'block_editor_settings_all', 'wp_docs_block_editor_settings', 10, 2 );

You must log in before being able to contribute a note or feedback.