function onYouTubeIframeAPIReady() {
  if (document.getElementById('video-player') === null) 
    return;
  
  CURRENT_PAGE_PLAYER = new YT.Player('video-player', {
    videoId: document
      .getElementById('video-player')
      .dataset
      .videoid,
    events: {
      onReady: skipVideoToHashTimecode
    }
  });
}
Wait until the YouTube Iframe-API has loaded.