isLoading isFetching 차이점

[ReactQuery] isLoading과 isFetching의 차이점에 대해 알아보자
❗ isLoading, isFetching의 차이점 ReactQuery에서 isLoading 및 isFetching 속성은 데이터의 로드 상태를 나타내는 데 사용된다. isLoading은 특정 쿼리에 대해 React Query에서 제공하는 속성이다. 쿼리가 현재 데이터를 가져오고 있는지 여부를 나타내는 boolean 값을 반환한다. 예를 들면 다음과 같다. import { useQuery } from 'react-query'; function ExampleComponent() { const { data, isLoading, error } = useQuery('exampleData', fetchData); if (isLoading) { return Loading...; } if (error) { retur..