skip to Main Content
import "./App.css";

import Header from "./components/Header/Header";

function App()
{
    return (
        <>
            <Header/>
        </>
      );
}

export default App;`

I cant understand what’s going wrong. I don’t think the compiler is reading that line.

2

Answers


  1. You can not leave the fragment <></> empty of with single child, it’s used for multiple components. you can put html element instead of fragment.

    Login or Signup to reply.
  2. export default App;`
    

    change to

    export default App;
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search