import React from "react";
import { BrowserRouter, Routes, Route } from "react-router-dom";
import { Home, Playlists, Profile, Queue, Tracks } from "./pages";
import { history } from "./utils/history";

// history.listen(() => console.log(history.location))   

const App = () => {
    return (
        <BrowserRouter history={history}>
            <Routes >
                <Route path="/" element={<Home />} />
                <Route path="profile" element={<Profile />} />
                <Route path="queue" element={<Queue />} />
                <Route path="tracks" element={<Tracks />} />
                <Route path="playlists" element={<Playlists />} />
            </Routes>
        </BrowserRouter>
    );
};

export default App;
