import './Navigation.css';

import {HashRouter,Link,Route,Routes} from "react-router-dom";

import Games from "../Pages/Games"
import Leagues from "../Pages/Leagues"
import React from "react";

class Navigation extends React.Component
{
  render()
  {
      return (
        <HashRouter>
          <div className="navBar">
            <Link className='navItem' to="/Leagues"><h2>Leagues</h2></Link>
            <Link className='navItem' to="/Games"><h2>My Games</h2></Link>
          </div>
          
          <Routes>
            <Route exact path="/" element={<Leagues/>}/>
            <Route exact path="/Leagues" element={<Leagues/>}/>
            <Route exact path="/Games" element={<Games/>}/>
          </Routes>     
        </HashRouter>    
      );
    }
}



export default Navigation;
