gitlab-lint-react
gitlab-lint-react copied to clipboard
fix: changing debounce behaviour, adding preventDefault to event on search input
This PR aims to fix two bugs on the search behaviour.
- Search stopped working during the fix of a warning regarding the debounce implementation, using useMemo with an inline func instead of useCallback (both in the end will have the same behaviour, but fixes the weird linting error and doesn't break)
- Pressing enter after typing the search query would result in the form post going off, added event.preventDefault() to called function (oops)