From 3f6734ee7abaa8c65ddda4fdbda022785d471ba0 Mon Sep 17 00:00:00 2001 From: hiroyuki kikuchi Date: Mon, 27 Jun 2022 09:12:06 +0900 Subject: [PATCH 1/3] fix(typo): Succesfully -> Successfully --- examples/optimistic-ui/pages/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/optimistic-ui/pages/index.js b/examples/optimistic-ui/pages/index.js index d45d27ab5..7c200d349 100644 --- a/examples/optimistic-ui/pages/index.js +++ b/examples/optimistic-ui/pages/index.js @@ -60,7 +60,7 @@ export default function App() { populateCache: newItem => { setState( - Succesfully mutated the resource and populated cache. + Successfully mutated the resource and populated cache. Revalidating... ) From b6c6f64f59f5f6e4343e0c800449cda77468b719 Mon Sep 17 00:00:00 2001 From: hiroyuki kikuchi Date: Mon, 27 Jun 2022 09:12:31 +0900 Subject: [PATCH 2/3] fix(typo): speical -> special --- _internal/utils/mutate.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_internal/utils/mutate.ts b/_internal/utils/mutate.ts index 4f4d1cd31..1e87ec35a 100644 --- a/_internal/utils/mutate.ts +++ b/_internal/utils/mutate.ts @@ -61,7 +61,7 @@ export async function internalMutate( const matchedKeys: Key[] = [] for (const key of cache.keys()) { if ( - // Skip the speical useSWRInfinite keys. + // Skip the special useSWRInfinite keys. !key.startsWith('$inf$') && keyFilter((cache.get(key) as { _k: Arguments })._k) ) { From 8305e750f5b3a366d8c4372b0435d6fcb04850d6 Mon Sep 17 00:00:00 2001 From: hiroyuki kikuchi Date: Mon, 27 Jun 2022 09:13:00 +0900 Subject: [PATCH 3/3] fix(typo): inital -> initial --- core/use-swr.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/use-swr.ts b/core/use-swr.ts index a11eef4ee..1d4be67b7 100644 --- a/core/use-swr.ts +++ b/core/use-swr.ts @@ -190,7 +190,7 @@ export const useSWRHandler = ( const data = isUndefined(cachedData) ? fallback : cachedData const error = cached.error - // Use a ref to store previous returned data. Use the inital data as its inital value. + // Use a ref to store previous returned data. Use the initial data as its initial value. const laggyDataRef = useRef(data) const returnedData = keepPreviousData