Render all requests data

This commit is contained in:
Vencislav Atanasov 2024-09-18 21:57:36 +03:00
parent c6e1ed6ef1
commit 77c88b2075
1 changed files with 43 additions and 1 deletions

View File

@ -1,10 +1,52 @@
import PropTypes from 'prop-types'; import PropTypes from 'prop-types';
import useEvents from './hooks/useEvents.js';
import useSpeakers from './hooks/useSpeakers.js';
import useTracks from './hooks/useTracks.js';
import useEventTypes from './hooks/useEventTypes.js';
import useHalls from './hooks/useHalls.js';
import useSlots from './hooks/useSlots.js';
export default function Schedule({ export default function Schedule({
conferenceId, conferenceId,
}) { }) {
const {
data: events,
} = useEvents(conferenceId);
const {
data: speakers,
} = useSpeakers(conferenceId);
const {
data: tracks,
} = useTracks(conferenceId);
const {
data: eventTypes,
} = useEventTypes(conferenceId);
const {
data: halls,
} = useHalls(conferenceId);
const {
data: slots,
} = useSlots(conferenceId);
return (<> return (<>
conference id: {conferenceId} <div>conference id: {conferenceId}</div>
<div>events:</div>
<div>{JSON.stringify(events)}</div>
<div>speakers:</div>
<div>{JSON.stringify(speakers)}</div>
<div>tracks:</div>
<div>{JSON.stringify(tracks)}</div>
<div>event types:</div>
<div>{JSON.stringify(eventTypes)}</div>
<div>halls:</div>
<div>{JSON.stringify(halls)}</div>
<div>slots:</div>
<div>{JSON.stringify(slots)}</div>
</>); </>);
} }