You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 10, 2020. It is now read-only.
At main.js:17 the location.hash is being updated multiple times as the user types in their query. The search function seems to work fine but clicking the back button causes the app to backtrack through each incremental search update. e.g. If the user searches for "asdf", the 1st back button click sets location.hash to "asd", the 2nd to "as", and so on.
This might easily be resolved by using a debounce function from a library like lodash, e.g.
$('table').on('search.dt', _.debounce(function(e, settings) {
var query = $("input[type=search]").val();
if (query)
location.hash = QueryString.stringify({q: query});
...
}, 1000));
The text was updated successfully, but these errors were encountered:
At main.js:17 the
location.hash
is being updated multiple times as the user types in their query. The search function seems to work fine but clicking the back button causes the app to backtrack through each incremental search update. e.g. If the user searches for "asdf", the 1st back button click sets location.hash to "asd", the 2nd to "as", and so on.This might easily be resolved by using a debounce function from a library like lodash, e.g.
The text was updated successfully, but these errors were encountered: