-
+ public static render(item: pageData) {
+ return
+
+
+
+
- }
-
- ;
+ {item.image &&
+
+
+
+ }
+
+ ;
+ }
}
-window.addEventListener('DOMContentLoaded', () => {
- handleQueryString();
- bindQueryStringChange();
- bindSearchForm();
-})
\ No newline at end of file
+window.addEventListener('load', () => {
+ setTimeout(function () {
+ const searchForm = document.querySelector('.search-form') as HTMLFormElement,
+ searchInput = searchForm.querySelector('input') as HTMLInputElement,
+ searchResultList = document.querySelector('.search-result--list') as HTMLDivElement,
+ searchResultTitle = document.querySelector('.search-result--title') as HTMLHeadingElement;
+
+ new Search({
+ form: searchForm,
+ input: searchInput,
+ list: searchResultList,
+ resultTitle: searchResultTitle
+ });
+ }, 0);
+})
+
+export default Search;
\ No newline at end of file