-
-
Save malihassan20/1b337804f371168d44f49bbd5ba709cd to your computer and use it in GitHub Desktop.
nextJs-tour-diary-app\pages\tour-detail.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import { Layout } from 'antd'; | |
import { withReduxSaga } from '../store/store'; | |
import { getTourDetail } from '../store/actions'; | |
import Wrapper from '../components/wrapper'; | |
import TourDetails from '../components/Tour/TourDetail'; | |
const { Content } = Layout; | |
class TourDetail extends Component { | |
static async getInitialProps({ store, query }) { | |
await store.dispatch(getTourDetail(query.tourId)); | |
} | |
render() { | |
return ( | |
<Wrapper title="Tour Detail"> | |
<Layout className="layout content-body-adj"> | |
<Content> | |
<TourDetails /> | |
</Content> | |
</Layout> | |
</Wrapper> | |
); | |
} | |
} | |
export default withReduxSaga(TourDetail); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment