• Resolved luvtoread25

    (@luvtoread25)


    My Yoast SEO was working fine this morning however, now I am unable to add a new/ update an existing post.
    i have troubleshot this and it’s just Yoast SEO plugin by itself causing me to not be able to create a new/ update an existing post.

    Even with the classic editor the plug in does not even show up.

    This is the error:

    i’m just quite confused and do not know what any of this means. Pls help ??

    TypeError: Cannot read property 'SnippetEditor' of undefined
        at https://thecuriousplanner.com/wp-content/plugins/wordpress-seo/js/dist/block-editor-1611.js:1:141386
        at zj (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:13:24396)
        at Th (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:10413)
        at tj (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:10342)
        at Te (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:10:7238)
        at https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:1114
        at unstable_runWithPriority (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react.min.js?ver=16.13.1:25:260)
        at Da (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:824)
        at Pg (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:1060)
        at ha (https://thecuriousplanner.com/wp-includes/js/dist/vendor/react-dom.min.js?ver=16.13.1:7:995)
Viewing 15 replies - 1 through 15 (of 15 total)
  • Plugin Support devnihil

    (@devnihil)

    @luvtoread25 We’re sorry to hear you are experiencing this issue on your site.

    Can you please confirm you are using the most recent version of Yoast SEO, version 16.1.1? You can learn more about updating here: https://yoast.com/help/how-can-i-update-my-free-plugin/

    Also, can you confirm you are using WordPress 5.7? You can check by clicking on the W in the top left and selecting About. If you need to update, please check with your host provider. Please know that if you are using an older version of WordPress Core you may experience unexpected behavior with Yoast. This guide explains more: https://yoast.com/why-we-dont-support-old-wordpress-versions/

    If you update to the most current version of WordPress and Yoast SEO, does this resolve the issue?

    If after ensuring that both WordPress, Yoast SEO, and your other plugins and themes are up to date the issue is still occurring, we’d next recommend performing a conflicting check to see whether another plugin or theme is interfering with the Yoast SEO Plugin. This will help us narrow down the exact cause and determine what the next steps are while saving you time.

    The fastest way to do this is to?deactivate all non-Yoast plugins and switch to a standard theme?like?Twenty Nineteen.?Test this on your development or staging site, if you have one. If not, we recommend using the?Health Check & Troubleshooting?plugin. This plugin allows you to run a conflict check?without affecting normal visitors to your site.

    If you’re unfamiliar with checking for conflicts, we’d like to point you to a step-by-step guide that will walk you through the process:?How to check for plugin conflicts.`

    i had exact same error:
    “The editor has encountered an unexpected error.
    TypeError: Cannot read property ‘SnippetEditor’ of undefined.”

    i deactivated Code Snippets. no change.
    i deactivated Yoast SEO. i gained access to the editor page. resolved.
    i REactivated Yoast SEO. got same error.
    “The editor has encountered an unexpected error.
    TypeError: Cannot read property ‘SnippetEditor’ of undefined.”

    *** i used a handful of very standard plugins and OceanWP theme. auto-updates on everything.

    no sure who or what the culprit is but the instability of the WP environment is a bit annoying. overall, WP sure beats hammering out the code i used to write (and never got DIVs & pics quite in the right spot!). ??

    • This reply was modified 3 years, 7 months ago by peter.

    I have this same problem, YOAST plugin is causing the error when activated. When I deactivate it works fine.

    TypeError: Cannot read property 'SnippetEditor' of undefined
        at block-editor-1611.js:1
        at zj (react-dom.min.js:13)
        at Th (react-dom.min.js:10)
        at tj (react-dom.min.js:10)
        at Te (react-dom.min.js:10)
        at react-dom.min.js:7
        at unstable_runWithPriority (react.min.js:2)
        at Da (react-dom.min.js:7)
        at Pg (react-dom.min.js:7)
        at ha (react-dom.min.js:7)
    Plugin Support devnihil

    (@devnihil)

    @usc333 @zerokarma We are sorry you’re having this issue. Per the forum guidelines, we ask that you please create a separate topic for the issue you are experiencing.

    That way it’s easier to track issues and provide assistance on your specific concerns on your specific site. Plus, you will get your own alerts for the issue rather than someone else’s. You may make a new topic here: https://www.ads-software.com/support/plugin/wordpress-seo/#new-post.

    roger that devnihil. u didn’t recommend to @luvtoread25 to deactivate Yoast SEO instead of perform 30,000 other tasks.
    personally, i eliminate the 1 thing causing a glitch & move on.
    (the Yoast Eye icon don’t integrate with Elementor and now, the subject Unexpected Error doesn’t allow me to fine-tune my SEO using Yoast.) get ur programmers movin! ??

    Hi @usc333,

    We’re not able to reproduce the error with the information we have, so it’s pretty standard practice on the WP forums to ask for a conflict check. If you can also do a conflict check with your setup to see where the problem is happening that would be super helpful.

    understood Ma’am. for retarded people like me it’s the fear of the cascading affects. change “A” only to find “B” & “C” went screwy (eg, changing themes).
    i do sincerely understand your point. my lay approach is to deactivate the turd (technical speak for us californians) and keep it movin’.
    yoast makes a great product — i like the interface more than MR (i think). but compatibility is stability and all that equates to time … which i (?we) ain’t none of ??
    love/peace — i’m sure the issue will resolve in ur next push.

    Plugin Support Michael Ti?a

    (@mikes41720)

    Hi @usc333

    We understand it may be daunting to perform a conflict check, but using the Health Check & Troubleshooting plugin allows you to go into troubleshooting mode, which will allow you to start with a default WP theme (such as TwentyTwenty) and no plugins enabled. But it won’t affect how your frontend users view the website, it will only be your view.

    From there, enabling the plugins (starting with Yoast SEO) one by one until the error or issue is reproducible. We hope you understand where we are coming from, as each website and set-up is totally different. This information would be helpful for us to identify where it’s coming from and how we can resolve it in the upcoming releases — https://yoast.com/help/how-to-check-for-plugin-conflicts/#plugin

    Plugin Support devnihil

    (@devnihil)

    We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new issue.

    same happens to me. And if I disable Yoast it goes away. So I don’t think it is resolved?

    how do i set this back to unresolved?

    anyway my issue is that regular posts cant be edited with yoast on – you get the unexpected error messsage – The editor has encountered an unexpected error.

    custom posts are fine though.

    turn yoast off and the error goes away

    @firecastdan: yoast plugin support will want you to “create a separate [new] topic for the issue you are experiencing.”
    personally, i suspected that new push would resolve (an update by yoast seo or other plugin), and i don’t have the pressure of keeping a commercial site operational.
    AS OF NOW: i don’t know how but i no longer have the “The editor has encountered an unexpected error” error.
    installing Classic Editor made the latter error go away immediately but i didn’t have the yoast seo functions (focus keyphrase, seo title, meta descrip, readability for my Pages; i don’t use Posts).
    then i logged in yesterday, and yoast functionality is back to normal.
    over the last week four plugins updated: yoast, UpdraftPlus, elementor, and my theme (oceanwp).
    over the last few years i no longer see or hear the word, ‘bug.’ if SW, then bug…. very simple….
    good luck.

    Thread Starter luvtoread25

    (@luvtoread25)

    I said in the first message i did all of the checks but it was the plug in that was the problem.
    I didn’t want to switch to the paid version (as Yoast said to another user with the same problem as me to do so) so I went with Rank Math and honestly, it is amazing! it’s so much better than Yoast… who i found to be quite unhelpful.

    @usc333 @firecastdan @zerokarma

    ISSUE STILL EXISTS (have identified where in the theme code it occurs and thus the cause)

    REGULAR POSTS EDIT ERROR – CAUSED BY YOAST PLUGIN WHEN USING CUSTOM THEME
    WordPress error – The editor has encountered an unexpected error.
    Occurs when editing regular POSTS in the admin area (Custom Post Types unaffected)

    Disabling Yoast plugin removes the error. Only happens on custom theme not the default WordPress ones.

    Error is located in the functions.php file.
    It is caused by the function that converts absolute links to reltive ones – The ‘post_link’ filter that uses the wp_make_link_relative() function
    Specifically the line that changes the URL variable – $url = wp_make_link_relative($url)

    When it occurs regarding plugin versions:
    Updating WordPress version on an older site is fine. Then when Yoast is updated to version 17.1 the post error starts happening

    THIS IS A YOAST ISSUE

    If any plugins or custom code hook ‘post_link’ after WordPress SEO it can generate a fatal error.

    Discussion here of issue – Wrong parameter in get_permalink
    when you call get_permalink($post); – $post is not a WP_Post or and ID but your Stdclass.
    If any plugins or custom code hook ‘post_link’ after WordPress SEO it can generate a fatal error.
    https://github.com/Yoast/wordpress-seo/issues/16308

    //relative links – rather than absolute for posts/page links
    function fcml_internal_link_to_relative( $url, $post, $leavename ) {
    //echo “<br />before url:” . $url;

    //if ( $post->post_type == ‘post’ || $post->post_type == ‘page’ ) {
    $url = wp_make_link_relative($url);
    //}
    //echo “<br />after url:” . $url;

    return $url;
    }
    add_filter( ‘post_link’, ‘fcml_internal_link_to_relative’, 10, 3 );
    add_filter( ‘page_link’, ‘fcml_internal_link_to_relative’, 10, 3 );

    NOTE: post_link causes the error – page_link is fine

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘YOAST SEO: ‘The Editor Has Encountered an Unexpected Error’ on Block Editor’ is closed to new replies.