Element type is invalid: expected a string (for built-in components) or a class/function

后端 未结 9 602
谎友^
谎友^ 2020-12-03 21:11
import React from \'react\';
import ReactDOM from \'react-dom\';
import Map from \'./components/map/container/map\';
import App from \'./App\';
import \'./index.css\         


        
9条回答
  •  余生分开走
    2020-12-03 21:36

    In my case I solved it changing the components: They were written in functions declarations and I change them by classical Class declarations (class App extends React.Component instead of function App() )

提交回复
热议问题