title: React: Embed tweet: Display text instead of tweet
body: <p>I am using a WYSIWYG editor to display embeded tweets in posts, in a React app. The issue is that my editor removes all the scripts tags before saving post content in the database, and the tweet is displayed as on the picture below.</p>
  
  <p><a href="https://i.stack.imgur.com/eGI3z.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/eGI3z.png" alt="enter image description here"></a></p>
  
  <p>The tweet code looks like this</p>
  
  <pre><code>&lt;blockquote class="twitter-tweet" data-lang="en"&gt;
    &lt;p lang="en" dir="ltr"&gt;
      ...
    &lt;/p&gt;
  &lt;/blockquote&gt;
  
  &lt;script async src="https://platform.twitter.com/widgets.js" charset="utf-8"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>I have tried to add the script in my template, just before the closing <code>body</code> tag, both with async and without async attribute, but then the tweets only render when I refresh the page.</p>
  
  <p>I have try this code:</p>
  
  <pre><code>&lt;div
     dangerouslySetInnerHTML={{
       __html: `
          ${post.content}
          &lt;script async src="https://platform.twitter.com/widgets.js" charset="utf-8"&gt;&lt;/script&gt;
      `
     }}
  /&gt;
  </code></pre>
  
  <p>With this, the twitter's widget HTML load as before, the script tag is loaded at the end of the post, but it still doesn't work.</p>
  
  <p>I don't know how I can get that tweet to be display normally.
  Please help.</p>