useEffect -> useMemo
This commit is contained in:
parent
af28539a02
commit
bb7f795175
@ -1,4 +1,4 @@
|
|||||||
import { Dispatch, SetStateAction, useEffect, useState } from "react";
|
import { Dispatch, SetStateAction, useMemo, useState } from "react";
|
||||||
import { ReactSortable, ReactSortableProps } from "react-sortablejs";
|
import { ReactSortable, ReactSortableProps } from "react-sortablejs";
|
||||||
import api, { baseUrl } from "./api";
|
import api, { baseUrl } from "./api";
|
||||||
|
|
||||||
@ -304,7 +304,7 @@ export default function Rankings() {
|
|||||||
setPlayers(data as Player[]);
|
setPlayers(data as Player[]);
|
||||||
}
|
}
|
||||||
|
|
||||||
useEffect(() => {
|
useMemo(() => {
|
||||||
loadPlayers();
|
loadPlayers();
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user