Yoast / yoast-acf-analysis

WordPress plugin that adds the content of all ACF fields to the Yoast SEO score analysis.
https://wordpress.org/plugins/acf-content-analysis-for-yoast-seo/
GNU General Public License v3.0
61 stars 20 forks source link

The word count is duplicated with Advanced Custom Fields Pro #316

Open suascat opened 2 years ago

suascat commented 2 years ago

Please give us a description of what happened.

With Yoast SEO Free 19.7.1, ACF Content Analysis for Yoast SEO 3.0.1, and Advanced Custom Fields PRO 6.0.1, there's an issue where the content analysis seems to double or duplicate and shows an incorrect number of the word count.

So if you have text that is 350 words, in the SEO analysis, it'll display 700 words.

If you go to your browser's console and use the YoastSEO.analysis.collectData().getText() script, you'll see that the text repeats twice.

If you deactivate ACF PRO and use the free version of ACF, the issue doesn't occur, so it appears to be specific to the PRO version of ACF.

Please describe what you expected to happen and why.

We expected that the word count assessment would be correct.

How can we reproduce this behavior?

  1. Install and activate Yoast SEO, ACF Content Analysis for Yoast SEO, and ACF PRO.
  2. Create a new post (no need to use any ACF fields, just use default editor)
  3. Add text and take note of the word count (example 100 words) and then check SEO analysis in the Yoast SEO meta box and see that the word count shows 200 words instead.

Technical info