Title: Insufficient Transformer Documentation
Last modified: August 31, 2016

---

# Insufficient Transformer Documentation

 *  Resolved [Alex Delgado](https://wordpress.org/support/users/alexdelgado/)
 * (@alexdelgado)
 * [10 years ago](https://wordpress.org/support/topic/insufficient-transformer-documentation/)
 * There is not enough documentation on the transformer class on github, facebook,
   or the code itself. The following tickets could easily be closed if someone could
   provide more insight (with examples) of how the transformer class actually works
   and how to extend it.
 * **Tickets Supporting My Claim**
    [https://wordpress.org/support/topic/transformer-rule-gallery?replies=1](https://wordpress.org/support/topic/transformer-rule-gallery?replies=1)
   [https://wordpress.org/support/topic/add-custom-fields-to-instant-article?replies=3](https://wordpress.org/support/topic/add-custom-fields-to-instant-article?replies=3)
   [https://wordpress.org/support/topic/correct-transformer-rule-for-caption-shortcode?replies=1](https://wordpress.org/support/topic/correct-transformer-rule-for-caption-shortcode?replies=1)
   [https://wordpress.org/support/topic/transformer-rule-question?replies=1](https://wordpress.org/support/topic/transformer-rule-question?replies=1)
   [https://wordpress.org/support/topic/please-help-with-correct-transformer-rule?replies=1](https://wordpress.org/support/topic/please-help-with-correct-transformer-rule?replies=1)
   [https://wordpress.org/support/topic/custom-transformer-rules-to-exclude-javascript-block?replies=1](https://wordpress.org/support/topic/custom-transformer-rules-to-exclude-javascript-block?replies=1)
   [https://wordpress.org/support/topic/correct-custom-rule-for-youtube-iframe-embed?replies=4](https://wordpress.org/support/topic/correct-custom-rule-for-youtube-iframe-embed?replies=4)
   [https://wordpress.org/support/topic/instagram-embeds-not-wrapped-in-op-social-tags?replies=4](https://wordpress.org/support/topic/instagram-embeds-not-wrapped-in-op-social-tags?replies=4)
 * I’ve got a custom shortcode that I’m working on which keeps getting filtered 
   out despite my best attempts at adding a “custom” rule. I would like to add the
   following code (which validates via facebook directly!) to the feed.
 *     ```
       <figure class="op-social">
       	<iframe>
       		<div id="fb-root"></div>
       		<div class="fb-video" data-href="'.$a['url'].'" data-allowfullscreen="true"></div>
       		<script>(function(d, s, id) {
       			var js, fjs = d.getElementsByTagName(s)[0];
       			if (d.getElementById(id)) return;
       			js = d.createElement(s); js.id = id;
       			js.src = "//connect.facebook.net/en_US/all.js#xfbml=1&version=v2.5";
       			fjs.parentNode.insertBefore(js, fjs);
       		}(document, "script", "facebook-jssdk"));</script>
       	</iframe>
       </figure>
       ```
   
 * Note that there is no “src” parameter to the iframe, because you can’t ifame 
   a fb video directly, but for some reason you have to put in an iframe anyway,
 * [https://wordpress.org/plugins/fb-instant-articles/](https://wordpress.org/plugins/fb-instant-articles/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Paulo](https://wordpress.org/support/users/demoive/)
 * (@demoive)
 * [10 years ago](https://wordpress.org/support/topic/insufficient-transformer-documentation/#post-7323040)
 * [@alexdelgado](https://wordpress.org/support/users/alexdelgado/), thank you so
   much for the feedback regarding the documentation and the extra effort to list
   related issues.
 * I’m happy to say that in the last week we’ve extended our documentation with 
   a section dedicated to giving clarity on how Transformer Rules work and how to
   configure them with supporting examples. I’ve provided more information in the
   duplicate GitHub issue you opened for any possible improvements and additional
   feedback you may have:
 * [https://github.com/facebook/facebook-instant-articles-sdk-php/issues/79](https://github.com/facebook/facebook-instant-articles-sdk-php/issues/79)
 * I’ll mark this issue as “Resolved” for now since the added resources should be
   sufficient to get you started in defining the rules needed to make the transformation
   of your article into an Instant Article successful.
 *  [Paulo](https://wordpress.org/support/users/demoive/)
 * (@demoive)
 * [10 years ago](https://wordpress.org/support/topic/insufficient-transformer-documentation/#post-7323041)
 * Hello again, [@alexdelgado](https://wordpress.org/support/users/alexdelgado/).
 * I’ve been going through the related tickets listed above to communicate the same
   about the improved docs. Of the ones listed, the following are still not marked
   as resolved in case you’d like to help communicate the same doc improvements 
   or provide some help in these threads:
 * [https://wordpress.org/support/topic/transformer-rule-gallery?replies=1](https://wordpress.org/support/topic/transformer-rule-gallery?replies=1)
   
   [https://wordpress.org/support/topic/correct-transformer-rule-for-caption-shortcode?replies=1](https://wordpress.org/support/topic/correct-transformer-rule-for-caption-shortcode?replies=1)
   [https://wordpress.org/support/topic/transformer-rule-question?replies=1](https://wordpress.org/support/topic/transformer-rule-question?replies=1)
   [https://wordpress.org/support/topic/please-help-with-correct-transformer-rule?replies=1](https://wordpress.org/support/topic/please-help-with-correct-transformer-rule?replies=1)
   [https://wordpress.org/support/topic/custom-transformer-rules-to-exclude-javascript-block?replies=1](https://wordpress.org/support/topic/custom-transformer-rules-to-exclude-javascript-block?replies=1)
 * Thanks again.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Insufficient Transformer Documentation’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/fb-instant-articles_8fa0a4.svg)
 * [Instant Articles for WP](https://wordpress.org/plugins/fb-instant-articles/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/fb-instant-articles/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/fb-instant-articles/)
 * [Active Topics](https://wordpress.org/support/plugin/fb-instant-articles/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/fb-instant-articles/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/fb-instant-articles/reviews/)

## Tags

 * [transformer](https://wordpress.org/support/topic-tag/transformer/)

 * 2 replies
 * 2 participants
 * Last reply from: [Paulo](https://wordpress.org/support/users/demoive/)
 * Last activity: [10 years ago](https://wordpress.org/support/topic/insufficient-transformer-documentation/#post-7323041)
 * Status: resolved