title: Render iFrame video using YouTubes JS API with Reactjs
body: <p>I've tried looking around for examples but all i have is <code>youtube-react</code> <code>npm</code> packages which I don't want since I want to do it and learn it myself.</p>
  
  <p>My issue is on the docs here:
  <a href="https://developers.google.com/youtube/iframe_api_reference" rel="nofollow">https://developers.google.com/youtube/iframe_api_reference</a>
  It tells me to provide an anchor tag for Google to append the iFrame depending on what you pass it.</p>
  
  <p>However, I have react on the server-side and use web-pack to compile it to the client-side my react component so far looks like :</p>
  
  <pre><code>import React from 'react';
  import { Link } from 'react-router'
  import classnames from 'classnames'
  
  const videoId = 'XxVg_s8xAms';
  
  export default React.createClass({
    getInitialState: function() {
      return {
        YTid: videoId,
      }
    },
    render() {
      return (
        &lt;section className="youtubeComponent-wrapper"&gt;
          &lt;div id="youtubePlayerAnchor"&gt;&lt;/div&gt;
        &lt;/section&gt;
      )
    }
  })
  </code></pre>
  
  <p>I've tried adding the code from the developer docs into a <code>script</code> tag onto the client but nothing happens nothing in console nothing.</p>
  
  <p>Is there any resources or could anyone point me in the right direction on how i'd go about handling this.</p>
  
  <p>Thanks!</p>