import Toaster from "./components/Helpers/Toaster";
import Routers from "./Routers";
import Default from "./components/Partials/Default";
import { Navigate, useLocation } from "react-router-dom";

function App() {
    const {pathname} = useLocation()
    return (
        <Default>
            <>
            {pathname.startsWith('/@') ?
                <Navigate to="/app" replace={true} />
            :
                <Routers />
            }
                <Toaster />
            </>
        </Default>
    );
}

export default App;
