title: Sanitize ACF WYSIWYG Content in Automattic's AMP plugin
body: <p>I use the <a href="https://www.advancedcustomfields.com/resources/flexible-content/" rel="nofollow noreferrer">ACF Flexible Content field</a> with subfields (WYSIWYG, etc) to build custom pages/CPT posts in Wordpress. I am using a custom child theme with AMP templates using the <a href="https://wordpress.org/plugins/amp/" rel="nofollow noreferrer">AMP for WordPress</a> plugin by Automattic.</p>
  
  <p>I am trying to sanitize the output of an ACF WYSIWYG field so that <code>&lt;img&gt;</code> tags are converted to <code>&lt;amp-img&gt;</code> tags. </p>
  
  <p>By default, the AMP plugin sanitizes <code>the_content</code> to replace certain tags so that they validate for AMP. Since the ACF WYSIWYG field content is outside of <code>the_content</code>, it is not being sanitized. Has anyone been able to sanitize custom fields so that the AMP validator finds no errors?</p>