title: React: Element type is invalid error when it shouldn't happen
body: <p>I get the following error when I try to use a component</p>
  
  <p><code>Uncaught Invariant Violation: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in. Check the render method of `MemberSearchBar`.</code></p>
  
  <p>I read other stack-question and it is about exporting it by default , i am already doing that.
  I am importing the component like:</p>
  
  <p><code>import MemberSearchBar from './member-search-bar';</code> ( I am absolutely sure the import path is correct)</p>
  
  <p>then I'm just using it, like <code>&lt;MemberSearchBar /&gt;</code></p>
  
  <p>the code for the component is</p>
  
  <pre><code>import React, { Component } from 'react';
  import debounce from 'lodash/debounce';
  import { StyledSearchInput } from './member-search-bar.styles';
  
  export default class MemberSearchBar extends Component {
    state = {
      searchText: '',
    };
  
    handleChange = e =&gt; {
      this.setState({ searchText: e.target.value });
      debounce(this.state.searchText, 300);
    };
  
    render() {
      return (
        &lt;React.Fragment&gt;
          &lt;StyledSearchInput
            isInline
            isSmall
            onChange={this.handleChange}
            value={this.state.value}
          /&gt;
        &lt;/React.Fragment&gt;
      );
    }
  }
  </code></pre>
  
  <p>Anyone has any ideea why I get that?</p>