Skip to content

Commit f44edf5

Browse files
committed
feat: remove dashboard
1 parent 3785b57 commit f44edf5

File tree

6 files changed

+7
-81
lines changed

6 files changed

+7
-81
lines changed

src/App.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,12 @@ import { ReactQueryDevtools } from 'react-query/devtools';
44
import { BrowserRouter, Route, Switch } from 'react-router-dom';
55
import './App.css';
66
import BenchmarkDetail from './components/Benchmarks/BenchmarkDetail';
7-
import Dashboard from './components/Dashboard/Dashboard';
7+
import Benchmarks from './components/Benchmarks/Benchmarks';
8+
import CreateBenchmark from './components/Benchmarks/CreateBenchmark';
89
import Landing from './components/Landing';
910
import Login from './components/Login';
1011
import Register from './components/Register';
1112
import PrivateRoute from './components/Routing/PrivateRoute';
12-
import Benchmarks from './components/Benchmarks/Benchmarks';
13-
import CreateBenchmark from './components/Benchmarks/CreateBenchmark';
1413

1514
function App() {
1615
const queryClient = new QueryClient();
@@ -29,7 +28,6 @@ function App() {
2928
<Route path="/register">
3029
<Register />
3130
</Route>
32-
<PrivateRoute path="/dashboard" component={Dashboard} />
3331
<PrivateRoute exact path="/benchmarks" component={Benchmarks} />
3432
<PrivateRoute
3533
exact

src/components/Benchmarks/BenchmarkDetail.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import useBenchmarkDetail from '../../hooks/benchmark';
88
import useProcessInterval, {
99
useLastSubmissionForUser,
1010
} from '../../hooks/submissions';
11-
import Result from '../Dashboard/Result';
11+
import Result from './Result';
1212
import Header from '../Page/Header';
1313
import Page from '../Page/Page';
1414

src/components/Dashboard/Dashboard.tsx

Lines changed: 0 additions & 72 deletions
This file was deleted.

src/components/Login.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const Login: React.FC = () => {
99
const { token, setToken } = useToken();
1010

1111
if (token) {
12-
history.push('/dashboard');
12+
history.push('/benchmarks');
1313
}
1414
const loginUser = async (event: any) => {
1515
event.preventDefault();
@@ -20,7 +20,7 @@ const Login: React.FC = () => {
2020
);
2121

2222
setToken(token);
23-
history.push('/dashboard');
23+
history.push('/benchmarks');
2424
};
2525

2626
return (

src/components/Register.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const Register: React.FC = () => {
1111
const [message, setMessage] = useState('');
1212

1313
if (token) {
14-
history.push('/dashboard');
14+
history.push('/benchmarks');
1515
}
1616
const registerUser = async (event: any) => {
1717
event.preventDefault();
@@ -46,7 +46,7 @@ const Register: React.FC = () => {
4646
);
4747

4848
setToken(token);
49-
history.push('/dashboard');
49+
history.push('/benchmarks');
5050
};
5151

5252
return (

0 commit comments

Comments
 (0)