Wordpress block editor (Gutenberg) crashes with unexpected error when editing text heading

Written by - 0 comments

Published on - last updated on August 21st 2023 - Listed in Wordpress CMS

When I wanted to write a new blog post on Geeker's Digest, I noticed the Wordpress block editor (Gutenberg) crashed. As soon as I wanted to change a parameter into a header (H1, H2, etc), the editor crashed and showed an error. After some analysis, it turns out this crash is caused by a plugin.

The editor has encountered an unexpected error

Let's start from the beginning. When I wanted to create a new blog post on a recently updated Wordpress (to the current and latest version 6.3), the block editor (which is called Gutenberg) crashed with an error as soon as I wanted to add or edit a text header.

As soon as I wanted to change the selected block "Header" into a header, the editor crashed and showed an error message "The editor has encountered an unexpected error."

The "Copy Error" button offers to copy the error message in the background. It is not very helpful though:


<!-- wp:paragraph -->
<!-- /wp:paragraph -->

We can see that a crash has happened inside the react-dom.min.js JavaScript - but not what is causing it.

Troubleshooting with browser console

By using the browser console (which you can open with [F12] key, at least in Chrome and Firefox), an "Uncaught Error" can be found when the crash happens.

This time we can see more. Right after the react-dom.min.js script there are other entries pointing to another JavaScript in the ultimate-addons-for-gutenberg plugin.

This is coming from the Spectra plugin, which offers additional functionalities and blocks for the Gutenberg block editor (such as Table of Content for example).

From the Spectra settings we can see that "Heading" is enabled. Unfortunately I was unable to only disable the Heading extension - at least in the free version.

So I decided to deactivate the plugin completely:

Wordpress plugin Spectra deactivated

Right after disabling the plugin, I was able to edit and add headers in the editor again. The crash is resolved. Surely the plugin maintainers will fix the bug soon.

Bug is fixed in 2.7.6

Meanwhile two updates of the Spectra plugin were released (2.7.5 on August 16th and 2.7.6 on August 18th). After installing the latest version 2.7.6, the block editor crash is gone when editing headings.

According to the plugin's changelog, the fix could have been in version 2.7.5:

    Fix: Global – Resolved an issue that was encountered when updating to WordPress 6.3 on some websites.

Or this fix in 2.7.6:

    Fix: Form – Resolved multiple styling issues on the frontend.

Add a comment

Show form to leave a comment

Comments (newest first)

No comments yet.