[react] query provider component name
Closed this issue · 1 comments
the provider.tsx
file that gets generated for react and next js projects (which wrap the entire app) has a vague name.
we should consider renaming it to something along the lines of react-query-provider.tsx
to make it more clear what the file is used for (including renaming the exported component to match)
Reason:
when looking at the complete list of providers in the app, Provider
is not descriptive whereas SolanaProvider
and ClusterProvider
are
This change will improve code readability and maintainability. Here's how you can do it:
// In react-query-provider.tsx
import React from 'react';
import { QueryClient, QueryClientProvider } from 'react-query';
const queryClient = new QueryClient();
const ReactQueryProvider: React.FC = ({ children }) => {
return {children};
};
export default ReactQueryProvider;