+
+ {loading &&
}
+ {errorMessage && (
+
+ )}
+ {!loading && !errorMessage && (
+
+ {memoizedSuggestions}
+
+ )}
+
+ );
};
export default Input;
-
diff --git a/src/utils/deboucne.ts b/src/utils/debounce.ts
similarity index 99%
rename from src/utils/deboucne.ts
rename to src/utils/debounce.ts
index 47a2c01..bb6cab3 100644
--- a/src/utils/deboucne.ts
+++ b/src/utils/debounce.ts
@@ -7,4 +7,4 @@ export const debounce = (callback: Function, wait: number) => {
callback(...args);
}, wait);
};
-}
\ No newline at end of file
+}
diff --git a/src/utils/fetch-data.ts b/src/utils/fetch-data.ts
index 547a287..2ee54ee 100644
--- a/src/utils/fetch-data.ts
+++ b/src/utils/fetch-data.ts
@@ -12,7 +12,7 @@ export async function fetchData(query: string): Promise