Add company overview skeleton and cache
This commit is contained in:
@@ -27,12 +27,12 @@ import type {
|
||||
ResearchArtifactSource
|
||||
} from '@/lib/types';
|
||||
|
||||
export function companyAnalysisQueryOptions(ticker: string) {
|
||||
export function companyAnalysisQueryOptions(ticker: string, options?: { refresh?: boolean }) {
|
||||
const normalizedTicker = ticker.trim().toUpperCase();
|
||||
|
||||
return queryOptions({
|
||||
queryKey: queryKeys.companyAnalysis(normalizedTicker),
|
||||
queryFn: () => getCompanyAnalysis(normalizedTicker),
|
||||
queryFn: () => getCompanyAnalysis(normalizedTicker, options),
|
||||
staleTime: 120_000
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user