diff --git a/public/static/index.js b/public/static/index.js index 515065a..c743497 100644 --- a/public/static/index.js +++ b/public/static/index.js @@ -32,3 +32,10 @@ searchBox.addEventListener('keyup', (e) => { searchWeb() } }) + +/** +* A function that clears the search input text when the clear button is clicked. +*/ +function clearSearchText() { + document.querySelector('.search_bar input').value = '' +}