title: Typescript error: Cannot redeclare block-scoped variable 'fetch'
body: <p>I am working on a proof of concept to fetch some simple JSON data from JSON-server to display in my react app. In doing so I am trying to call fetch to load the data directly. When I do so.</p>
  
  <blockquote>
    <p><strong>ERROR:</strong> "cannot redeclare block-scoped variable 'fetch'.</p>
  </blockquote>
  
  <p>My question is, when working in regular Typescript, how can I get around this issue? </p>
  
  <pre><code>import React, { Component } from 'react';
  import '../HeaderBar/HeaderBar.css';
  
  type StatusBarProps = {};
  type StatusBarState = {
      launch_timer: boolean;
      foreGroundTimer: number;
  
  };
  class StatusBar extends Component&lt;StatusBarProps, StatusBarState&gt; {
      timerId: number;
      constructor() {
          super();
          this.state = {
              launch_timer: true,
              foreGroundTimer: -1,
          };
      }
      componentDidMount() {
          window.fetch('localhost:3000/StatusComponent').then(results =&gt; {
              return results.json();
          }).then(data =&gt; {
              let systemOff = 'green';
              let systemOn = 'gray';
              let statusBarBlocks = data.StatusComponent.map((Status) =&gt; {
                  return(
                      &lt;div className="blockBar" id={Status.id} key={Status.key} style={{ backgroundColor: (this.state.foreGroundTimer &gt;= Status.id) ? systemOff : systemOn }}&gt; {Status.Name} &lt;/div&gt;
                  );
              });
              this.setState({statusBarBlocks: statusBarBlocks});
          });
      }
      componentWillUnmount() {
          clearInterval(this.timerId);
      }
      tick() {
          this.setState({ launch_timer: !this.state.launch_timer, foreGroundTimer: (this.state.foreGroundTimer + 1) % 26 });
      }
      render() {
  
          return (
              &lt;div className="location"&gt;
                  &lt;div className="col-xs-6"&gt;
                  {this.state.statusBarBlocks}
                  &lt;/div&gt;
              &lt;/div&gt;
          );
      }
  }
  export default StatusBar;
  </code></pre>
  
  <p>edit 1: the location of the issue is @types/whatwg-fetch/index.d.ts which leads me to believe this is an issue with typescript. I have implemented Isomorphic-fetch to no avail. </p>