redirect root dir to leduc holdem

This commit is contained in:
songyih 2020-01-28 21:38:37 -08:00
parent d75a427d64
commit 62f71d3655
1 changed files with 4 additions and 1 deletions

View File

@ -1,11 +1,14 @@
import React from 'react'; import React from 'react';
import { BrowserRouter as Router, Route } from "react-router-dom"; import { BrowserRouter as Router, Route, Redirect } from "react-router-dom";
import DoudizhuGameView from './view/DoudizhuGameView'; import DoudizhuGameView from './view/DoudizhuGameView';
import LeducHoldemGameView from './view/LeducHoldemGameView'; import LeducHoldemGameView from './view/LeducHoldemGameView';
function App() { function App() {
return ( return (
<Router> <Router>
<Route exact path="/">
<Redirect to="/leduc-holdem" />
</Route>
<Route path="/doudizhu" component={DoudizhuGameView} /> <Route path="/doudizhu" component={DoudizhuGameView} />
<Route path="/leduc-holdem" component={LeducHoldemGameView} /> <Route path="/leduc-holdem" component={LeducHoldemGameView} />
</Router> </Router>