mirror of
https://github.com/umami-software/umami.git
synced 2026-02-12 00:27:11 +01:00
Updated fetch hook API.
This commit is contained in:
commit
69b317386a
21 changed files with 112 additions and 76 deletions
|
|
@ -17,14 +17,16 @@ export default function EventsChart({ websiteId, token }) {
|
|||
const { data } = useFetch(
|
||||
`/api/website/${websiteId}/events`,
|
||||
{
|
||||
start_at: +startDate,
|
||||
end_at: +endDate,
|
||||
unit,
|
||||
tz: timezone,
|
||||
url: query.url,
|
||||
token,
|
||||
params: {
|
||||
start_at: +startDate,
|
||||
end_at: +endDate,
|
||||
unit,
|
||||
tz: timezone,
|
||||
url: query.url,
|
||||
token,
|
||||
},
|
||||
},
|
||||
{ update: [modified] },
|
||||
[modified],
|
||||
);
|
||||
const datasets = useMemo(() => {
|
||||
if (!data) return [];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue